Skip to content
Back to Documentation

COKIQ docs

WordPress: WP Consent API

The COKIQ WordPress plugin shares each visitor's choice with the WP Consent API, so Site Kit by Google, WooCommerce and other plugins respect it.

Best for

WordPress and WooCommerce site owners using the COKIQ plugin.

What the report shows

These are the product-side evidence areas COKIQ can surface when the site has the required scan, banner, consent log, and blocker data.

Registered with the WP Consent API

COKIQ declares itself as the consent plugin, sets the consent type to opt-in, and maps its categories to WordPress categories.

Category mapping

Necessary to functional, Preferences to preferences, Analytics to statistics and statistics-anonymous, Marketing to marketing.

Works with Site Kit by Google

Site Kit reads the WP Consent API, so GA4 and Google Ads tags added by Site Kit follow the same choice. COKIQ also sends Google Consent Mode v2 signals itself.

Setup steps

Step 1

Install the WP Consent API plugin

Install and activate "WP Consent API" from the WordPress plugin directory (free).

Step 2

Install COKIQ 0.2.0 or newer

Download the COKIQ plugin zip from cokiq.com/downloads/cokiq-wordpress-0.2.0.zip, upload it under Plugins > Add New > Upload, and activate it.

Step 3

Add your site key

Settings > COKIQ Consent: paste the site key from your COKIQ dashboard and save.

Step 4

Check the status line

The settings page shows whether the WP Consent API is active and registered.

Step 5

Test

Open the site in a private window, accept or reject, then run wp_has_consent("statistics") in the browser console. It should match your choice.

Implementation checklist

  • WP Consent API active
  • COKIQ shows as registered
  • Consent type is optin
  • wp_has_consent matches the banner choice
  • Site Kit tags follow the choice

FAQ

Do I need the WP Consent API plugin?

It is optional. COKIQ works without it, but installing it lets other WordPress plugins read the visitor's choice.

Is the plugin on WordPress.org?

Version 0.2.0 is available as a download from cokiq.com today.