WordPressOfficial Plugin

Cookie Consent for WordPress

Free WordPress plugin for GDPR, CCPA, and Google Consent Mode v2 compliance. Install in 2 minutes. No coding, no theme editing, no developer needed.

How to install

1

Install the plugin

Download the plugin ZIP and upload it in WordPress under Plugins > Add New > Upload Plugin, then activate it.

2

Click Connect

Go to Settings > Legal Banner and click Connect to Legal Banner. Sign in or create a free account and confirm your site.

3

You are live

You come back to WordPress with the banner showing and verified. Design the banner and review the cookie scan in your LegalBanner dashboard.

Features

One-click connect

Click Connect in the plugin, sign in or create a free account, and confirm. You come back to WordPress with the banner live and your site being scanned. No codes or API keys to copy.

Loads first, holds trackers

The plugin puts the banner first in every page, before your theme and other plugins add their scripts, so analytics and ad tags wait for consent. No theme files to edit.

Cookie settings button and policy pages

A "Cookie settings" block and shortcode let visitors change their choice. One click creates WordPress pages for your published privacy and cookie policies, always showing the latest version.

Google Consent Mode v2

Native support for Google Consent Mode v2. It turns on automatically when Google tags are detected and sends consent signals to Google Analytics 4, Google Ads, and Google Tag Manager.

Cookie scanner

Automatically detects all cookies and third-party trackers on your WordPress site. Maps them to consent categories. Notifies you when new trackers appear.

GDPR & CCPA compliant

Holds the trackers the scan finds until the visitor consents. Visitors in the EU, UK, Canada and Brazil are asked first; visitors in the US get an opt-out banner with a Do Not Sell or Share choice, and Global Privacy Control is honored.

Lightweight

About 14KB gzipped and isolated in Shadow DOM, so it never clashes with your theme.

Works with any theme

Works with themes such as Astra, GeneratePress, Divi, Elementor and Kadence. No theme file editing required.

WooCommerce ready

Works with WooCommerce. Trackers the scan finds are held until consent on product, cart and checkout pages too.

Requirements

  • WordPress 5.8 or higher
  • PHP 7.4 or higher
  • A LegalBanner account (free plan works)
  • HTTPS enabled on your WordPress site

Frequently Asked Questions

Is the WordPress plugin free?

Yes. The plugin itself is completely free. It connects to your LegalBanner account, which has a free plan (1 site, all banner features).

Does it work with WooCommerce?

Yes. The plugin is fully compatible with WooCommerce. Consent is collected on all pages including product, cart, and checkout pages.

Does it support Google Consent Mode v2?

Yes. Google Consent Mode v2 turns on automatically when Google tags are detected on your site. No extra setup is needed in WordPress or Google Tag Manager.

Will it slow down my site?

Very little. The banner script is about 14KB gzipped, served from our CDN and cached by the browser.

Can I use it on multisite (WPMU)?

Yes. Install the plugin on each site in your multisite network. Each site connects to a separate LegalBanner site for independent configuration.

What happens if I deactivate the plugin?

The consent banner stops appearing. Your configuration and consent logs remain in your LegalBanner dashboard. Reactivate anytime.

Add cookie consent to WordPress in 2 minutes

GDPR, CCPA, Google Consent Mode v2, and all 20 US state privacy laws. Free plan available.

LegalBanner for WordPress: Cookie Consent Plugin for GDPR and CCPA | LegalBanner