AdSense cookie consent

Please note that this is no longer being updated. Kindly visit the new Cookiebot support area ( for updated guides, articles and FAQs. If you do not find the answer to your question there, you are welcome to post it in the Cookiebot community (

To enable prior consent on ads served by Google AdSense/DoubleClick, add the following attributes (in bold text) to the existing AdSense script:

<script async src="//" type="text/plain" data-cookieconsent="marketing"></script>
<ins class="adsbygoogle"
<script type="text/plain" data-cookieconsent="marketing">
(adsbygoogle = window.adsbygoogle || []).push({});

With AdSense there is no option to opt out of cookies on a session level to display ads without serving cookies. Therefor it is not possible to display ads from AdSense if the user opts out of marketing cookies.

Feedback and Knowledge Base