WordPress OSINT, maintenance or security needs? Reach out!
TLDWP

Plugin: wp-consent-api (Used by 82,110 domains)

WP Consent API

πŸ‘€ Rogier Lankhorst πŸ“¦ v2.0.1 πŸ”— Plugin Homepage

WP Consent API is a plugin that standardizes the communication of accepted consent categories between plugins. It requires a cookie banner plugin and, at least, one other plugin that supports the WP Consent API.

With this plugin, all supporting plugins can use the same set of methods to read and register the current consent category, allowing consent management plugins and other plugins to work together, improving compliance with privacy laws.

WARNING: the plugin itself will not handle consent. It will show you how many plugins you have without Consent API support and will improve compliance on your site by ensuring smooth communication between cookie banner plugins and plugins that set cookies or track user data.

What problem does this plugin solve?

Currently, it is possible for a consent management plugin to block third-party services like Facebook, Google Maps, Twitter, etc. But if a WordPress plugin places a PHP cookie, a consent management plugin cannot prevent this.

Secondly, some plugins integrate the tracking code on the clientside in javascript files that, when blocked, break the site.

Or, if such a plugin’s javascript is minified, causing the URL to be unrecognizable and won’t get detected by an automatic blocking script.

Lastly, the blocking approach requires a list of all types of URL’s that tracks data. A generic API where plugins adhere to can greatly
facilitate a webmaster in getting a site compliant.

Does usage of this API prevent third-party services from tracking user data?

Primary this API is aimed at compliant first-party cookies or tracking by WordPress plugins. If such a plugin triggers, for example, Facebook,
usage of this API will be of help. If a user embeds a Facebook iframe, a blocking tool is needed that initially disables the iframe and or scripts.

Third-party scripts have to blocked by blocking functionality in a consent management plugin. To do this in core would be to intrusive, and is also not applicable to all users: only users with visitors from opt-in regions such as the European Union require such a feature. Such a feature also has a risk of breaking things. Additionally, blocking these and showing a nice placeholder requires even more sophisticated code, all of which should in my opinion not be part of WordPress core, for the same reasons.

How does it work?

There are two indicators that together tell if consent is given for a specific consent category, e.g., β€œmarketing”:
1) the region based consent_type, which
can be opt-in, opt-out, or other possible consent_types;
2) and the visitor’s choice: not set, allow, or deny.

The consent_type is a function that wraps a filter, β€œwp_get_consent_type”. If there’s no consent management plugin to set it, it will return false. This will cause all consent categories to return true, allowing cookies to be set on all categories.

If opt-in is set using this filter, a category will only return true if the value of the visitor’s choice is β€œallow”.

If the region based consent_type is opt-out, it will return true if the visitor’s choice is not set or is β€œallow”.

Clientside, a consent management plugin can dynamically manipulate the consent type and set several cookie categories.

A plugin can use a hook to listen for changes or check the value of a given category.

Categories and most other stuff can be extended with a filter.

Existing integrations

Categorized, and sorted alphabetically

Example plugin

  • Example plugin. The plugin basically consists of a shortcode, with a div that shows a tracking or not tracking message. No actual tracking is done πŸ™‚

Consent Management Providers

Consent Requiring Plugins

Demo site

wpconsentapi.org
Below are the plugins used to set up the demo site:

javascript, consent management plugin

//set consent type
window.wp_consent_type = 'optin'

//dispatch event when consent type is defined. This is useful if the region is detected server side, so the consent type is defined later during the pageload
let event = new CustomEvent('wp_consent_type_defined');
document.dispatchEvent( event );


//consent management plugin sets cookie when consent category value changes
wp_set_consent('marketing', 'allow');

javascript, tracking plugin

//listen to consent change event
document.addEventListener("wp_listen_for_consent_change", function (e) {
  var changedConsentCategory = e.detail;
  for (var key in changedConsentCategory) {
    if (changedConsentCategory.hasOwnProperty(key)) {
      if (key === 'marketing' && changedConsentCategory[key] === 'allow') {
        console.log("just given consent, track user")
      }
    }
  }
});

//basic implementation of consent check:
if (wp_has_consent('marketing')){
  activateMarketing();
  console.log("set marketing stuff now!");
} else {
  console.log("No marketing stuff please!");
}

PHP

//declare compliance with consent level API
$plugin = plugin_basename( __FILE__ );
add_filter( "wp_consent_api_registered_{$plugin}", '__return_true' );

/**
* Example how a plugin can register cookies with the consent API
 * These cookies can then be shown on the front-end, to the user, with wp_get_cookie_info()
 */

function my_wordpress_register_cookies(){
    if ( function_exists( 'wp_add_cookie_info' ) ) {
        wp_add_cookie_info( 'AMP_token', 'AMP', 'marketing', __( 'Session' ), __( 'Store a unique User ID.' ) );
    }
}
add_action('plugins_loaded', 'my_wordpress_register_cookies');


if (wp_has_consent('marketing')){
//do marketing stuff
}

Service-level consent

In addition to category-based consent, the API supports service-level consent control. This allows consent management plugins to grant or deny consent for specific services (like β€˜google-analytics’ or β€˜facebook-pixel’) independently from their category. When checking service consent with wp_has_service_consent(), the API first checks if explicit consent exists for that service. If no explicit consent is set, it falls back to the consent status of the service’s category. This enables fine-grained control: a user might accept statistics cookies in general, but explicitly deny a specific analytics service.

Service consent can be checked and set both server-side (PHP) and client-side (JavaScript):

PHP:

//check if a specific service has consent
if ( wp_has_service_consent( 'google-analytics' ) ) {
    //activate google analytics
}

//check if a service is explicitly denied
if ( wp_is_service_denied( 'facebook-pixel' ) ) {
    //service was explicitly denied by user
}

//set service consent
wp_set_service_consent( 'google-analytics', true ); //grant consent
wp_set_service_consent( 'facebook-pixel', false ); //deny consent

//listen for service consent changes
add_action( 'wp_consent_service_changed', function( $service, $consented ) {
    error_log( "Service {$service} consent changed to: " . ( $consented ? 'granted' : 'denied' ) );
}, 10, 2 );

JavaScript:

//check service consent
if ( wp_has_service_consent( 'youtube' ) ) {
    //activate tracking
}

//check if explicitly denied
if ( wp_is_service_denied( 'facebook-pixel' ) ) {
    //service denied
}

//set service consent
wp_set_service_consent( 'youtube', true );

//listen for service consent changes
document.addEventListener( 'wp_consent_api_status_change_service', function( e ) {
    console.log( 'Service: ' + e.detail.service + ', consented: ' + e.detail.value );
});

Any code suggestions? We’re on GitHub as well!

DomainExposuresHeadersLast Checked
j*m*.it βœ… β€” 2026-03-28 02:18:32
m*p*s*.ski (WP 6.8.5) βœ… β€” 2026-03-28 02:17:27
e*i*w*i*h*.net βœ… β€” 2026-03-28 02:16:22
b*r*i*t*i*.ch (WP 6.9.4) βœ… β€” 2026-03-28 02:09:53
s*h*e*e*s*u*e.de (WP 6.9.4) βœ… β€” 2026-03-28 02:09:53
k*n*e*t*-*n*-*e*l*u*s*.de βœ… β€” 2026-03-28 02:06:41
t*g*l.eu (WP 6.9.4) βœ… β€” 2026-03-28 02:05:21
l*w*m*a*t.org βœ… β€” 2026-03-28 02:05:21
m*p*n*.de βœ… β€” 2026-03-28 02:01:07
h*a*t*z*n*.it (WP 6.9.4) βœ… β€” 2026-03-28 01:58:31
n*-*r*s*u*r.nl (WP 6.9) βœ… β€” 2026-03-28 01:56:13
t*c.gal βœ… β€” 2026-03-28 01:55:08
s*a*t*a*k.fr βœ… β€” 2026-03-28 01:52:38
e*p*s*t*r*a*o*.it βœ… β€” 2026-03-28 01:52:37
m*r*a*t*g*o*p.cat βœ… β€” 2026-03-28 01:51:09
m*n*p*w*r*n*v*r*i*y.in (WP 6.9.4) βœ… β€” 2026-03-28 01:50:04
h*n*e*n*i*o*t*o*p*g*i*.fr (WP 6.9.4) βœ… β€” 2026-03-28 01:46:37
a*s*e*i*a.it (WP 6.9.1) βœ… β€” 2026-03-28 01:44:24
e*v*l*e*-*o*x.ch (WP 6.9.4) βœ… β€” 2026-03-28 01:44:24
c*s*i*l*o*i*e*o.it (WP 6.9.4) βœ… β€” 2026-03-28 01:34:00
t*a*s*o*m*t*o*a*p*y*h*t*e*a*y.org βœ… β€” 2026-03-28 01:33:04
g*i*e*i*-*o*e*n*.ch (WP 6.9.4) βœ… β€” 2026-03-28 01:19:28
u*b*n*d*c*d*m*.org βœ… β€” 2026-03-28 01:17:21
s*r*i*e*-*p*o.fr (WP 6.8.2) βœ… β€” 2026-03-28 01:14:50
o*c.org βœ… β€” 2026-03-28 01:07:05
v*l*a*i*n*l*a.it (WP 6.9.4) βœ… β€” 2026-03-28 01:04:01
s*o*e*a*b*s*i*e*n*i*k*.fi (WP 6.9.4) βœ… β€” 2026-03-28 01:00:17
p*c*o.fi (WP 6.9.4) βœ… β€” 2026-03-28 01:00:17
v*l*a*e*v*t*c*t*r*e.it (WP 6.9.1) βœ… β€” 2026-03-28 01:00:17
e*o*u*c*s.pl βœ… β€” 2026-03-28 00:57:56
m*t*m*r*e*i*g.ca βœ… β€” 2026-03-28 00:54:27
s*l*m*r*a.pt (WP 6.9.4) βœ… β€” 2026-03-28 00:54:27
n*r*i*c*t*r*n*.ee (WP 6.9.4) βœ… β€” 2026-03-28 00:54:26
l*f*u*e*s*i*t*a*c*l*i*o*s*.fr (WP 6.9.4) βœ… β€” 2026-03-28 00:47:17
s*h*r*a*.de πŸ”“ β€” 2026-03-28 00:44:49
b*c*e*l*s*j*u*n*y.lk (WP 6.9.4) βœ… β€” 2026-03-28 00:42:51
l*c*l*a*d*n*r.net (WP 6.9.4) βœ… β€” 2026-03-28 00:41:10
f*s*.foundation (WP 6.9.4) βœ… β€” 2026-03-28 00:37:30
m*r*t*m*b*s*n*s*c*l*e*e.ca (WP 6.9.4) βœ… β€” 2026-03-28 00:33:47
s*b*e*u*s*r*h*.fr (WP 6.9.4) βœ… β€” 2026-03-28 00:32:25
s*-*i*t*r*n*e.de (WP 6.9.4) βœ… β€” 2026-03-28 00:30:04
o*g*s*l*t*o*.de (WP 6.9.4) βœ… β€” 2026-03-28 00:25:40
s*f*y.at (WP 6.8.3) βœ… β€” 2026-03-28 00:23:50
r*a*e*e*g*a.it (WP 6.9.4) βœ… β€” 2026-03-28 00:21:30
r*d*g.org (WP 6.9.4) βœ… β€” 2026-03-28 00:19:47
m*e*s*o*l*.net (WP 6.9.1) βœ… β€” 2026-03-28 00:16:03
j*g*l.co (WP 6.9) βœ… β€” 2026-03-28 00:10:01
b*l*i*n*r*c*s.org (WP 6.7.2) βœ… β€” 2026-03-28 00:10:01
r*h*g*r*o*n*n.at βœ… β€” 2026-03-28 00:09:09
p*n*r*t*-*n*i*e.de βœ… β€” 2026-03-28 00:09:09
r*t*o*i*c*i*l*b.com (WP 6.9.4) βœ… β€” 2026-03-28 00:04:35
w*e*l*h*i*-*i*h*s.de βœ… β€” 2026-03-28 00:02:22
m*e*d*n*n*i*e.nl (WP 6.9.4) βœ… β€” 2026-03-28 00:00:34
v*x*e*.ro (WP 6.9.4) βœ… β€” 2026-03-27 23:56:34
z*r*v*t*h*.sk (WP 6.6.5) βœ… β€” 2026-03-27 23:56:34
g*e*g*r*e*.hr (WP 6.9.4) πŸ“„ β€” 2026-03-27 23:41:16
s*t*h*o*u*m*r*e*t.org βœ… β€” 2026-03-27 23:36:59
c*s*i*c*e*i*r*s*.at βœ… β€” 2026-03-27 23:36:59
r*l*i*-*l*c*g*.fr βœ… β€” 2026-03-27 23:35:57
g*a*n*i*a*e.net (WP 6.9.4) βœ… β€” 2026-03-27 23:34:32
r*e*.lt βœ… β€” 2026-03-27 23:34:32
r*g*r*c*t*f*r*.org (WP 6.9.4) βœ… β€” 2026-03-27 23:31:42
b*o*e.pl (WP 6.9.4) βœ… β€” 2026-03-27 23:25:00
t*c*e*o*o*y*0*0.it (WP 6.9.4) βœ… β€” 2026-03-27 23:20:33
s*c*p*a.mx (WP 6.9.4) βœ… β€” 2026-03-27 23:14:42
g*o*v*b*.ch βœ… β€” 2026-03-27 23:09:33
t*m*r*.it (WP 6.8.1) βœ… β€” 2026-03-27 23:08:07
p*l*a*r*.it (WP 6.9.4) βœ… β€” 2026-03-27 23:04:51
b*l*i*g*s*m*h*n*.org βœ… β€” 2026-03-27 23:03:42
c*m*u*e*m*n.gr (WP 6.9.4) βœ… β€” 2026-03-27 23:03:42
n*r*t*l*e*n*r*i.se (WP 6.9.4) βœ… β€” 2026-03-27 23:02:30
f*i.co βœ… β€” 2026-03-27 23:01:41
b*r*i*0*0.de (WP 6.9.4) βœ… β€” 2026-03-27 22:55:12
a*o*o*.plus (WP 6.9.4) βœ… β€” 2026-03-27 22:52:32
r*o*d*s*a*k*e*i*n*.com βœ… β€” 2026-03-27 22:52:32
i*a*.org βœ… β€” 2026-03-27 22:49:59
r*-*n*r*i*s*5.fr βœ… β€” 2026-03-27 22:48:54
c*n*o*m*n*s*r*e*.org βœ… β€” 2026-03-27 22:48:54
g*t*u*a.bg βœ… β€” 2026-03-27 22:47:39
b*m*e*h.fr (WP 6.9.4) βœ… β€” 2026-03-27 22:41:56
c*n*r*r*t*s.org (WP 6.9.1) βœ… β€” 2026-03-27 22:40:39
r*f*e*t*r.io βœ… β€” 2026-03-27 22:40:38
s*v*n*-*i*h*.org βœ… β€” 2026-03-27 22:38:32
s*m*i*.io (WP 6.9) βœ… β€” 2026-03-27 22:37:35
a*i*-*u*s*.fr (WP 6.9.4) βœ… β€” 2026-03-27 22:36:22
t*m.cz βœ… β€” 2026-03-27 22:32:48
m*i*o*n*u*e.net βœ… β€” 2026-03-27 22:32:48
l*t*t*d*v*r*e.fr βœ… β€” 2026-03-27 22:31:34
c*t*l*n*d*p*e*s*.fr (WP 6.9.4) βœ… β€” 2026-03-27 22:28:55
c*m*e*c*a*m*r*g*g*b*o*e*.org (WP 6.9.4) βœ… β€” 2026-03-27 22:27:48
n*x*i*v*s*.mx βœ… β€” 2026-03-27 22:26:19
d*b*n*t*a*l*r*.fr βœ… β€” 2026-03-27 22:23:21
l*y*e*.fr βœ… β€” 2026-03-27 22:22:20
f*e*o*f*c*s.mx (WP 6.9.4) βœ… β€” 2026-03-27 22:18:07
s*u*w*r.de (WP 6.9.4) βœ… β€” 2026-03-27 22:13:38
z*a*t*r*e*.nl βœ… β€” 2026-03-27 22:09:18
g*r*e*h*h*a*a*.org (WP 6.9.4) βœ… β€” 2026-03-27 22:07:55
c*i*w*b.fr (WP 6.9.4) βœ… β€” 2026-03-27 22:06:25
r*f*e*h*u*.fr (WP 6.9.4) βœ… β€” 2026-03-27 22:06:25
l*s*r*n*a*s.press βœ… β€” 2026-03-27 22:06:25

Top 50 Plugins

Plugin Count
elementor 3,987,002
contact-form-7 3,380,007
elementor-pro 2,188,808
woocommerce 1,902,461
revslider 1,294,555
js_composer 810,247
essential-addons-for-elementor-lite 591,253
wp-rocket 573,010
jetpack 544,319
header-footer-elementor 541,569
elementskit-lite 517,670
gutenberg-core 467,268
google-analytics-for-wordpress 433,557
instagram-feed 427,027
google-site-kit 413,098
wpforms-lite 402,174
astra-sites 399,665
cookie-law-info 388,347
complianz-gdpr 378,552
gravityforms 359,717
litespeed-cache 347,748
sitepress-multilingual-cms 319,274
bluehost-wordpress-plugin 299,132
gtranslate 257,502
coblocks 235,082
cookie-notice 227,389
premium-addons-for-elementor 197,185
mailchimp-for-wp 191,665
sg-cachepress 188,426
astra-addon 186,443
bb-plugin 185,148
the-events-calendar 185,125
pro-elements 183,570
click-to-chat-for-whatsapp 180,354
creame-whatsapp-me 178,795
LayerSlider 173,557
custom-fonts 172,085
wp-smushit 172,076
popup-maker 170,060
gutenberg 168,554
royal-elementor-addons 159,719
tablepress 155,669
ultimate-addons-for-gutenberg 154,374
woocommerce-gateway-stripe 150,229
pixelyoursite 149,027
smart-slider-3 148,304
duracelltomi-google-tag-manager 143,944
cleantalk-spam-protect 138,770
metform 135,480
fusion-builder 134,730

Top 50 Themes

Theme Count
hello-elementor 1,226,355
astra 1,113,331
Divi 982,193
pub 305,778
generatepress 231,189
flatsome 226,965
h4 213,417
Avada 195,537
oceanwp 168,910
kadence 147,007
twentytwentyfive 126,311
bb-theme 122,529
blocksy 121,497
twentytwentyfour 119,034
enfold 117,890
cocoon-master 117,522
salient 115,187
woodmart 100,351
betheme 98,814
twentyseventeen 89,093
dt-the7 78,067
neve 69,983
swell 63,243
twentytwentyone 60,201
bridge 58,735
lightning 53,644
twentytwentythree 52,862
twentytwenty 49,875
Avada-Child-Theme 44,261
gox 42,052
Impreza 40,373
bricks 39,742
Newspaper 39,031
twentytwentytwo 38,847
yith-wonder 32,697
storefront 31,533
extendable 30,980
themify-ultra 30,875
pro 30,174
twentyfifteen 29,900
uncode 29,547
epik-redesign 29,351
sydney 28,871
twentysixteen 28,652
go 25,836
porto 25,493
Total 25,492
hestia 23,155
popularfx 22,128
thrive-theme 21,738