Google Search Results Maximizer

Google disabled the option to display/show more than 10 results. This script allows you to get 100 Google search results per page again.

คุณจะต้องติดตั้งส่วนขยาย เช่น Tampermonkey, Greasemonkey หรือ Violentmonkey เพื่อติดตั้งสคริปต์นี้

You will need to install an extension such as Tampermonkey to install this script.

คุณจะต้องติดตั้งส่วนขยาย เช่น Tampermonkey หรือ Violentmonkey เพื่อติดตั้งสคริปต์นี้

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         Google Search Results Maximizer
// @version      1.0
// @namespace    https://github.com/Purfview/Google-Search-Results-Maximizer
// @homepage     https://github.com/Purfview/Google-Search-Results-Maximizer
// @supportURL   https://github.com/Purfview/Google-Search-Results-Maximizer/issues
// @icon         https://www.google.com/s2/favicons?sz=64&domain=google.com
// @license      MIT
// @description  Google disabled the option to display/show more than 10 results. This script allows you to get 100 Google search results per page again.
// @match        *://*.google.com/search?*
// @grant        none
// @run-at       document-start
// ==/UserScript==

(function() {
    'use strict';

    function modifySearchURL() {
        let url = new URL(window.location.href);
        let params = url.searchParams;

        if (params.has('num') && params.get('num') !== '100') {
            params.set('num', '100');
        } else if (!params.has('num')) {
            params.append('num', '100');
        }

        let newUrl = url.toString();
        if (newUrl !== window.location.href) {
            window.location.replace(newUrl);
        }
    }

    modifySearchURL();
})();