Google Consent Mode v2 is required for WordPress sites targeting users in the European Economic Area. It uses an API to communicate a visitor’s cookie choices to Google Ads and GA4. Without it, your tracking tags may collect data illegally or fail to report accurately. This guide explains the four consent signals, how to configure them in WordPress, and how to verify the implementation is live.
Why is my wordpress site not compliant with google consent mode v2?
You are likely asking this because you see warnings in Google Ads or Tag Assistant, or you are preparing for stricter enforcement. The core issue is that Consent Mode v2 is not just a toggle. It is a set of four specific data points that must be sent to Google before any other tag runs. If your site only sends the old v1 signals, or if it does not send any signals at all, Google treats the lack of consent as a denial. This leads to lost data or compliance flags.
The v2 update introduced two new parameters: ad_user_data and ad_personalization. These sit alongside the original analytics_storage and ad_storage signals. All four must be present in your consent state. If you are running a cookie banner plugin that was built for v1, it may not be sending the new parameters. That is the most common reason for non-compliance.
The four consent signals explained
To implement this correctly, you need to understand what each signal controls. Google uses these signals to decide whether to collect data or model it.
- analytics_storage: Controls whether Google can store cookies and local storage for Google Analytics. If set to "denied", GA4 will not set cookies.
- ad_storage: Controls whether Google can store cookies for advertising purposes. If set to "denied", Google Ads will not set cookies.
- ad_user_data: This is new in v2. It controls whether Google can use user data for advertising purposes. If denied, Google will not collect personally identifiable information for ads.
- ad_personalization: This is also new in v2. It controls whether Google can use data to personalize ads. If denied, personalized ads and remarketing are disabled.
Most WordPress sites need to handle all four. If you only run GA4, you technically only need analytics_storage, but Google recommends enabling all four for future-proofing and to avoid partial compliance issues.
Setting the default consent state
The first step in implementation is setting the default state. This state applies before the visitor has interacted with your cookie banner. For GDPR compliance, the default state for all four signals must be "denied".
In Google Tag Manager, or in a plugin that manages tags, you will find a section for Consent Mode. You need to ensure the default values are set as follows:
- analytics_storage: denied
- ad_storage: denied
- ad_user_data: denied
- ad_personalization: denied
This ensures that no data is collected until the user explicitly agrees. If you set any of these to "granted" by default, you are collecting data without consent, which is a violation.
Implementing the update call
Once the user interacts with your cookie banner, you must update the consent state. This happens via a JavaScript function or a plugin setting. The function is gtag('consent', 'update', {...}).
When the user clicks "Accept All", you send:
gtag('consent', 'update', {
'analytics_storage': 'granted',
'ad_storage': 'granted',
'ad_user_data': 'granted',
'ad_personalization': 'granted'
});
When the user clicks "Reject All" or "Necessary Only", you send:
gtag('consent', 'update', {
'analytics_storage': 'denied',
'ad_storage': 'denied',
'ad_user_data': 'denied',
'ad_personalization': 'denied'
});
If your banner allows granular choices, you map each choice to the corresponding signal. For example, if a user accepts analytics but rejects ads, you set analytics_storage to "granted" and ad_storage to "denied".
Verifying the setup works
You cannot just assume the code works. You need to verify that the signals are being sent correctly on your live site. The first step is to check if the consent mode code is actually present. You can run a quick check using the consent mode checker, which tells you if the four signals are being detected on your homepage.
For a deeper technical check, use Google Tag Assistant. Here is how:
- Install the Tag Assistant Chrome extension.
- Open your WordPress site in Chrome.
- Open Tag Assistant and click "Start".
- Interact with your cookie banner. Click "Accept".
- Look at the Tag Assistant panel. You should see a "Consent" section.
- Verify that all four signals show "granted" after acceptance.
- Refresh the page. Click "Reject" on the banner.
- Verify that all four signals show "denied".
If Tag Assistant does not show the consent signals, your code is not firing. Check your browser console for JavaScript errors. A common error is that the gtag function is not defined before the consent call. Ensure your Google tag script loads before the consent update code.
Common implementation mistakes
Most issues stem from timing or scope. Here are the most frequent errors:
- Loading order: The consent mode code must run before the Google tag initializes. If the tag initializes first, it may ignore the consent state.
- Missing signals: Only sending
analytics_storageandad_storage. You must includead_user_dataandad_personalizationfor v2 compliance. - Hardcoding consent: Setting consent to "granted" in the code for testing and forgetting to revert it. This is a critical compliance failure.
- Plugin conflicts: Some caching plugins or security plugins strip out the consent script. Test your site with caching disabled to isolate the issue.
If you are using a plugin like Complianz or CookieYes, ensure you enable the "Google Consent Mode v2" option in the plugin settings. These plugins handle the JavaScript for you, but you must verify the signals are correct using Tag Assistant.
Basic vs Advanced mode
Google offers two modes: Basic and Advanced.
- Basic Mode: Blocks all non-essential tags until consent is granted. No data is collected or modeled. This is the simplest and safest option for most WordPress sites.
- Advanced Mode: Allows Google to model data for users who deny consent. This can improve reporting accuracy but requires more complex implementation. You must ensure you have a valid legal basis for modeling data.
For most small businesses and coaches, Basic Mode is sufficient. Advanced Mode is only necessary if you rely heavily on Google Ads conversion data and need modeled conversions to optimize campaigns. If you are not running large ad budgets, stick with Basic Mode to reduce complexity and risk.
Troubleshooting with Tag Assistant
If your signals are not showing in Tag Assistant, follow these steps:
- Open your browser console (F12).
- Look for errors related to
gtagorconsent. - Check if the Google tag script is loading. If it is blocked by an ad blocker, disable the blocker for testing.
- Ensure the consent update function is being called. You can add a
console.log('Consent updated')inside your update function to verify it runs. - Check if your plugin is overriding the consent settings. Some plugins have their own consent management that may conflict with Tag Manager.
If you are using Google Tag Manager, go to the "Consent" section in the admin panel. Ensure the consent initialization settings are set to "denied" for all four signals. Then, create a "Consent Initialization" trigger that fires on "All Pages". This ensures the default state is set before any other tags run.
When to use server-side tracking
Client-side consent mode is the standard approach, but it has limitations. If your site uses aggressive ad blockers or privacy tools, client-side tags may be blocked entirely. In these cases, server-side tracking can help. Server-side tagging moves the tag execution to your server, where it is less likely to be blocked. However, it requires more setup and maintenance.
If you are struggling with client-side implementation or need to bypass ad blockers, consider server-side tracking. This approach centralizes your tag management and can improve reliability. It is not a replacement for consent mode, but it complements it by ensuring tags fire even when client-side scripts are blocked.
Final checklist
Before you consider the setup complete, run through this checklist:
- Default consent is set to "denied" for all four signals.
- The consent update function is called when the user interacts with the banner.
- All four signals are updated correctly based on user choice.
- Tag Assistant confirms the signals are changing as expected.
- No JavaScript errors are present in the console.
- Your cookie banner text clearly explains what each consent option does.
- You have documented the implementation for future reference.
If you follow these steps, your WordPress site will be compliant with Google Consent Mode v2. This protects you from legal issues and ensures your tracking data is accurate. Regularly review your setup, especially when you update plugins or change your cookie banner.
For more on how tracking systems work, see how to add tags in Google Tag Manager. If you need help with your current setup, read how to check if consent mode v2 is enabled.