Greasy Fork is available in English.

Google Referer

Redirect google to HongKong domain

  1. // ==UserScript==
  2. // @name Google Referer
  3. // @namespace http://tampermonkey.net/
  4. // @version 2024.02.09.1
  5. // @description Redirect google to HongKong domain
  6. // @author Dynesshely
  7. // @license AGPL
  8. // @match https://*.google.com*
  9. // @icon https://img.catrol.cn/avatar/avatar-head-only.png
  10. // @grant none
  11. // ==/UserScript==
  12.  
  13. (function() {
  14. 'use strict';
  15.  
  16. const url = new URL(window.location.href);
  17.  
  18. if (url.search == '') {
  19. window.location.href = "https://www.google.com.hk/";
  20. return;
  21. }
  22.  
  23. var query = url.searchParams.get('q');
  24.  
  25. window.location.href = "https://www.google.com.hk/?q=" + query;
  26. })();