🧪 BETA This site is in active development and some features may still change

How to add a cookie consent bar in a Blogger theme (supports PDPA and AdSense)

If your site uses Analytics or AdSense, informing visitors and requesting consent for cookies is not just a matter of courtesy, it is a requirement of both the law and the ad platform. This article teaches you how to add a cookie bar to a Blogger theme with BlogKub, one that remembers acceptance and is customizable, and explains PDPA and AdSense along the way.

Updated 14 July 2026   About a 9 minute read   Level: Beginner

Quick summary: add the Cookie bar (Consent) block in BlogKub, set the text, the privacy policy link, and the background color, then Export the XML and upload it to Blogger. You get a floating card in the bottom-left that remembers acceptance (no repeat showing) and supports PDPA and AdSense. On mobile it spans the full width along the edge. Do not forget to create a privacy policy page to link to.

A cookie consent bar in the bottom-left of a Blogger site with an accept button and a policy link
A cookie bar in the bottom-left corner: it remembers acceptance, supports PDPA and AdSense, and lets you edit the text, policy link, and color.

Why a Blogger site with ads or Analytics needs a cookie bar

A cookie bar is a notice to visitors that the site uses cookies, with a button to accept. Cookies are small files a site stores in the browser to remember information, such as settings, visit statistics, or the display of relevant ads. When your site installs Google Analytics or AdSense, it means cookies are being used to collect visitor data, which must be disclosed.

For site owners in Thailand, this relates to PDPA (the Personal Data Protection Act), which emphasizes informing and requesting consent before collecting data. And if you use AdSense, Google's own policy requires publishers to obtain consent for the use of cookies from users in many regions. Having a cookie bar is therefore both compliance with requirements and a way to build trust in your site.

This article gives general information for understanding, not legal advice. If your site collects sensitive data or has a large audience, you should consult a PDPA expert to prepare a complete policy.

How BlogKub's cookie bar works

BlogKub's cookie bar shows as a floating card in the bottom-left of the screen, with text announcing the use of cookies, a link to the privacy policy page, and an accept button. The highlight is that when a visitor clicks accept, the system remembers it in the browser and does not show the bar again on later visits, so it does not repeatedly bother readers.

Because it is a fixed floating card, it does not push the main content around, so it does not affect the layout or the speed score. On mobile the bar spans the full width along the edge for easy reading and tapping (the same approach as the language menu), without covering important content.

How to add the cookie bar in BlogKub, step by step

  1. Add the cookie bar block. Open the left library, the "Add-ons" category, and drag the "Cookie bar (Consent)" block in.
  2. Set the text, policy link, and color. Click the block to set the cookie notice text, the accept button text, the policy link text, the policy page URL, and the bar background color to match your site's design.
  3. Create a privacy policy page. In Blogger, create a new page called "Privacy Policy" explaining how the site collects and uses data, then take that page's URL into the policy link of the cookie bar.
  4. Export the XML and upload. Click Export, then take the file to blogger.com → Theme → three-dot menu → Backup/Restore → select the XML file.

How to write appropriate cookie bar text

The text in the bar should not be long or vague. Communicate directly what the site uses cookies for. A good example is "This website uses cookies to improve your experience and analyze traffic", followed by a "Privacy Policy" link and an "Accept" button. The principles are:

  • State the purpose briefly, such as to analyze traffic or show ads, so users understand what they are accepting.
  • Include a link to the full policy, for those who want to read more detail.
  • Make the accept button clear, using easy words like "Accept" or "OK".

The cookie bar and AdSense: points to watch

If you intend to earn from AdSense on your Blogger site, cookie consent matters even more, because Google requires publishers to obtain consent for the use of cookies for personalized advertising in many regions. Having a cookie bar together with a clear policy page helps your site comply with requirements and reduces the risk around the approval or standing of your AdSense account.

Besides the cookie bar, the privacy policy page should also state that the site uses AdSense and that third parties may use cookies to show interest-based ads, which is standard wording AdSense recommends having.

Another point worth knowing is that in some regions with strict laws, such as the European Union, Google requires publishers to use a certified consent management system. If many of your readers come from those regions, you should study AdSense's additional requirements. But for a blog focused mainly on Thai readers, a cookie bar with a clear policy page is a suitable starting point that covers the basic needs well.

PDPA basics for bloggers

PDPA, or the Personal Data Protection Act, is a Thai law that sets principles for the collection, use, and disclosure of personal data. For a general blogger, what to understand is that when your site collects visitor data, for example through Analytics or advertising cookies, you should inform users and give them the chance to know what is happening with their data.

The key principles the cookie bar helps address are "transparency" and "notice". A bar that shows clear text with a link to the full policy is the first step to making your site communicate with users honestly. Even a small personal blog may have low legal risk, but building good habits from the start helps the site grow with confidence, and be ready when visitors increase or when you start earning from ads.

What should be in the privacy policy page

The privacy policy page is the companion to the cookie bar, because the bar links to it. Here are the basic topics it should include to be complete and credible.

  • What data the site collects, such as visit data through cookies, statistics from Analytics, or data users enter themselves (if any).
  • What the data is used for, such as improving content, analyzing traffic, or showing relevant ads.
  • Third parties involved, such as stating that the site uses Google Analytics and AdSense, which may use cookies to show interest-based ads (standard wording AdSense recommends).
  • Users' rights and a contact channel, such as how to turn off cookies in the browser, and a channel to ask about data.

You can create this page easily as a page in Blogger, then take the URL into the policy link of the cookie bar. When both parts work together, your site communicates about data with users completely and professionally.

Common problems and how to fix them

The cookie bar does not show

It may be because you already clicked accept, so the system remembers it. Try opening in incognito mode or clearing the site data in your browser, and the bar will show again.

The bar overlaps another floating button

The bar sits in the bottom-left. If there is another floating button nearby, move that button to the right side so they do not overlap.

The policy link goes to a blank page

Check that you created the privacy policy page in Blogger and copied the correct URL into it. If there is no page yet, create it first.

Best practices

  • Always enable the cookie bar if the site uses Analytics or AdSense, for compliance with PDPA and ad policy.
  • Create and link a privacy policy page that fully explains data collection and use.
  • Write the bar text short, clear, direct, and unambiguous.
  • Test on both desktop and mobile to make sure the bar does not cover important content and accept is easy to click.

Wrapping up

The cookie bar is a basic element that a site using Analytics or AdSense should have, both to comply with PDPA and the ad platform's policy, and to build trust with readers. With BlogKub you just add the cookie bar block, set the text and policy link, and Export it to use. The system shows a bar that remembers acceptance and does not bother readers again, working well on both desktop and mobile. Do not forget to pair it with a fully written privacy policy page.

Frequently asked questions (FAQ)

Is a cookie bar necessary for a Blogger site?

It is necessary if your site stores cookies to analyze traffic or show ads, for example using Google Analytics or AdSense. Both Thailand's PDPA law and AdSense policy advise informing visitors and requesting consent for the use of cookies.

Does BlogKub's cookie bar remember acceptance?

Yes. When a visitor clicks accept, the system saves it in the browser and does not show the bar again on later visits, so it does not repeatedly bother readers.

Can I edit the text and policy link in the cookie bar?

Yes. You can set the cookie text, the accept button text, the policy link text, the policy URL, and the bar background color yourself in the block settings.

Where does the cookie bar show, and does it affect the layout?

It shows as a floating card in the bottom-left of the screen (on mobile it spans the full width along the edge). Being a floating position, it does not push the main content around, so it does not affect the layout or speed.

Do I also need a privacy policy page?

You should have one, because the cookie bar usually links to a policy page explaining how the site collects and uses data. It is both an AdSense requirement and a trust builder under PDPA principles. You create this page in Blogger and put its URL into the bar.


Part of the BlogKub feature guide series. Content and schema (HowTo + FAQPage) ready to publish on blogkub.com.

Menu
Home Templates Builder Docs Blog
Log in Get started