Auto Fill Google Cookie Consent

Using Greasemonkey

If you automatically delete cookies whenever you close your browser, you will have to answer the cookie consent message every time you use Google search.

With a single click you can give away your privacy. Not willing to do that? Then you have to manually go through a list of options with no default values, a tedious process clearly designed to discourage you.

These two simple greasemonkey scripts automatically decline all personalization options. These scripts address the Dutch language dialogs, but can be easily adapted to your language.

Google main script (www.google.*)

// ==UserScript==
// @name     Google main
// @include  https://www.google.*
// @require  https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js
// @version  1
// @grant    none
// ==/UserScript==

$(document).ready(function() {
    setTimeout(function() {
        var clickEvent = new MouseEvent('click', {
            view: window,
            bubbles: true,
            cancelable: true
        });
        $("button div:contains('Aanpassen')")[0].dispatchEvent(clickEvent);
    }, 50);
});
// ==UserScript==
// @name     Google consent
// @include  https://consent.google.*
// @require  https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js
// @version  1
// @grant    none
// ==/UserScript==

$(document).ready(function() {
    setTimeout(function() {
        var clickEvent = new MouseEvent('click', {
            view: window,
            bubbles: true,
            cancelable: true
        });
        $("button:contains('Uit')").each(function() {
            this.dispatchEvent(clickEvent);
        });
        setTimeout(function() {
            $("button:contains('Bevestigen')")[0].dispatchEvent(clickEvent);
        }, 200);
    }, 200);
});