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

Plugin: wp-consent-api (Used by 51,810 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
f*e*m*o*a*i*g.com (WP 6.9.4) βœ… F 2026-06-03 20:53:05
b*a*i*r*g*a*.com βœ… F 2026-06-03 20:53:05
i*s*.com (WP 7.0) βœ… F 2026-06-03 20:50:26
t*e*a*h*v*h*s*n.com βœ… F 2026-06-03 20:50:09
b*a*t*y*n*v*s.com βœ… A 2026-06-03 20:50:06
d*m*r*o*3*5.gr βœ… F 2026-06-03 20:43:46
a*a*e*i*t*i.com βœ… D 2026-06-03 20:43:18
i*s*e*r*p*.com βœ… F 2026-06-03 20:42:43
a*a*d*a*g*l.com (WP 6.8.5) βœ… F 2026-06-03 20:36:22
b*a*a*v*a*e*.com (WP 7.0) βœ… F 2026-06-03 20:36:02
m*l*y*a*l*u*g*.com (WP 7.0) βœ… B 2026-06-03 20:35:44
b*a*a*u*m*n*u.com (WP 5.9.3) ⚠️ F 2026-06-03 20:33:08
i*n*a*g*e.com (WP 7.0) πŸ”“ F 2026-06-03 20:30:53
b*a*a*p*l*e*e*s.com (WP 7.0) βœ… F 2026-06-03 20:29:37
f*e*l*n*n*w*.com (WP 7.0) βœ… F 2026-06-03 20:28:58
f*e*l*n*-*g.com βœ… F 2026-06-03 20:26:31
b*a*a*n*x*z*n.com βœ… F 2026-06-03 20:25:16
b*u*g*s.a*r*p*r*.fr (WP 6.9) βœ… F 2026-06-03 20:21:30
b*a*a*l*c*n*e*x*e*t.com (WP 7.0) βœ… F 2026-06-03 20:20:27
t*e*u*c*r*p*r*.com βœ… F 2026-06-03 20:16:43
f*e*l*n*i*g*i*r*.com (WP 7.0) βœ… F 2026-06-03 20:16:15
b*o*.d*v*.o*g.uk (WP 7.0) βœ… F 2026-06-03 20:13:25
m*r*u*i*e*1*.com (WP 7.0) βœ… F 2026-06-03 20:11:59
f*e*l*n*e*s*c*d*m*.com (WP 6.8.5) βœ… F 2026-06-03 20:07:02
t*e*u*e*c*t*e*.com (WP 7.0) βœ… D 2026-06-03 20:06:06
m*r*a*e*o*m*.com (WP 7.0) βœ… F 2026-06-03 20:05:07
i*l*s*g*.com (WP 6.8.5) βœ… F 2026-06-03 20:04:08
m*l*o*r*t*e*.com βœ… D 2026-06-03 20:03:30
a*a*e*y*u*c*p.com βœ… F 2026-06-03 19:59:38
f*e*l*n*e*d*s*b*a*d.com βœ… D 2026-06-03 19:58:13
m*l*t*r*v*h*c*e*d*t*.com βœ… F 2026-06-03 19:57:33
a*a*e*p*d*.com βœ… F 2026-06-03 19:56:34
a*a*e*m*n*w*l*n*s*.com (WP 7.0) βœ… F 2026-06-03 19:56:34
i*s*g*t*.w*s*w*o*o*e.com βœ… B 2026-06-03 19:54:44
t*e*f*o*e*s.com βœ… F 2026-06-03 19:53:22
b*a*a*b*l*g*.com (WP 6.9.4) βœ… F 2026-06-03 19:53:08
l*s*l*s*a*f*e*-*r.d*v.h*t*o.cloud (WP 7.0) βœ… C 2026-06-03 19:53:03
r*t*o*a*s*o*.c*.uk βœ… F 2026-06-03 19:46:01
t*e*u*s*i*o*h*p*i*e*s*o*.com βœ… B 2026-06-03 19:41:11
m*n*u*l*a*u*.com (WP 6.9.4) βœ… D 2026-06-03 19:38:07
m*n*o*a*r.com (WP 7.0) βœ… D 2026-06-03 19:38:06
b*d*c*s*.hu (WP 7.0) πŸ”“ D 2026-06-03 19:36:12
a*a*e*e*f*l*s.com βœ… F 2026-06-03 19:34:36
i*h*a*.com βœ… F 2026-06-03 19:34:17
c*d*a*.es βœ… F 2026-06-03 19:33:48
f*e*k*n*f*p*t*s*u*g*.com (WP 7.0) βœ… F 2026-06-03 19:30:42
a*a*e*c*p*.com βœ… F 2026-06-03 19:30:42
a*a*e*c*p.com βœ… F 2026-06-03 19:30:42
f*e*k*d*t*r*e*.com βœ… F 2026-06-03 19:30:40
s*g*a.fi βœ… C 2026-06-03 19:30:13
n*x*.inc (WP 6.9.4) βœ… F 2026-06-03 19:25:38
g*l*e*s*n*t*.com βœ… F 2026-06-03 19:23:43
i*d*e*.com (WP 7.0) βœ… B 2026-06-03 19:23:12
i*d*s.com βœ… F 2026-06-03 19:23:11
b*a*t*m*h*m*.com (WP 7.0) βœ… D 2026-06-03 19:20:02
i*c*i*i*a*d*f*n*e.com (WP 6.9.4) βœ… F 2026-06-03 19:14:02
t*e*u*l*c*e*v*c*a*l*a*c*.com (WP 6.9.4) βœ… D 2026-06-03 19:12:26
n*e*f*m*t*.com (WP 6.9.4) βœ… F 2026-06-03 19:05:35
a*a*o*s*l*.com (WP 7.0) βœ… F 2026-06-03 19:04:13
f*e*h*n*-*e*i*n.com βœ… F 2026-06-03 19:01:31
b*a*e*c*a.com βœ… F 2026-06-03 18:59:38
m*m*r*a*f*s*a*e*.com (WP 7.0) βœ… F 2026-06-03 18:58:11
f*e*g*v*r*m*n*c*l*p*o*e*u*d*.com βœ… D 2026-06-03 18:57:45
t*e*r*v*n*e*a*a*i*e.com βœ… F 2026-06-03 18:54:54
b*a*r*a*.com (WP 7.0) βœ… F 2026-06-03 18:54:08
f*e*f*r*g*m*s.com βœ… F 2026-06-03 18:45:38
f*e*f*r*-*u*d*r*m*s*e*y*g*m*s.com βœ… F 2026-06-03 18:45:38
a*y*s*o*e.com (WP 7.0) βœ… F 2026-06-03 18:43:54
v*n*s*a*i*r*.com (WP 7.0) βœ… F 2026-06-03 18:43:53
t*e*r*p*r*y*u*t*o*h*u*e.com (WP 7.0) βœ… F 2026-06-03 18:43:07
b*y*u*h*o*p*t*l*t*.com (WP 7.0) βœ… F 2026-06-03 18:42:32
i*x*o*z*.com βœ… D 2026-06-03 18:38:52
f*e*f*o*i*a*o*p*n*.com (WP 6.9.4) βœ… C 2026-06-03 18:38:34
b*w*r*d*n*.com (WP 7.0) βœ… F 2026-06-03 18:38:11
a*v*t*.com βœ… D 2026-06-03 18:35:08
a*v*c*t*r*n*l*i.com βœ… F 2026-06-03 18:35:07
m*l*s*o*e*a*a*e*y*x.com (WP 6.9.4) βœ… F 2026-06-03 18:34:50
t*e*r*m*s*g*e*r*s*.com βœ… A 2026-06-03 18:34:40
i*u*s*f*w*r*.com βœ… F 2026-06-03 18:32:34
m*l*a*o*g*.com (WP 7.0) βœ… C 2026-06-03 18:31:41
t*e*r*f*t*c*.com (WP 7.0) βœ… F 2026-06-03 18:26:45
t*e*r*f*t*a*n*h*r.com βœ… F 2026-06-03 18:26:44
f*e*d*w*l*a*s*n*i*e.com βœ… F 2026-06-03 18:24:43
m*l*s*o*e*c*d*m*t*.com (WP 6.9.4) βœ… F 2026-06-03 18:23:28
q*e*.c*m.tw (WP 7.0) βœ… F 2026-06-03 18:22:36
m*l*o*s*l*t*o*s.com (WP 7.0) βœ… D 2026-06-03 18:20:46
t*e*r*f*p*d*a*t.com (WP 6.9.4) πŸ”“ F 2026-06-03 18:20:24
t*e*r*d*c*r*m*s*c*l.com βœ… F 2026-06-03 18:14:20
o*b*a*t*l*a*.c*m.au βœ… F 2026-06-03 18:13:11
f*e*d*m*o*r*s*.com (WP 7.0) βœ… D 2026-06-03 18:12:27
s*l*n*a*i*g*f*t*.com βœ… F 2026-06-03 18:10:26
i*s*r*i*e*o*n*.com βœ… F 2026-06-03 18:09:46
a*u*t*a*y*g*c*a*i*m*n*i*i.com (WP 7.0) βœ… F 2026-06-03 18:09:35
m*l*n*t*n*o*g*.com (WP 7.0) βœ… C 2026-06-03 18:08:22
m*l*s*r*f*.com (WP 7.0) βœ… F 2026-06-03 18:07:45
r*c*s*l.be βœ… F 2026-06-03 18:00:49
f*e*d*m*o*f*n*a*.com βœ… F 2026-06-03 18:00:35
a*u*l*a*c*n*a*a.com (WP 6.9.4) βœ… D 2026-06-03 17:58:41
f*e*d*m*h*t*n*c*.com βœ… F 2026-06-03 17:53:09
m*l*n*i*m*e*i*a*.com (WP 7.0) βœ… F 2026-06-03 17:52:33

Top 50 Plugins

Plugin Count
elementor 1,819,196
contact-form-7 1,789,483
elementor-pro 1,060,662
woocommerce 824,782
revslider 623,770
jetpack 470,465
js_composer 436,870
wp-rocket 337,948
essential-addons-for-elementor-lite 297,183
gravityforms 269,158
complianz-gdpr 259,951
cookie-law-info 234,187
instagram-feed 230,506
google-site-kit 224,321
sitepress-multilingual-cms 223,618
google-analytics-for-wordpress 216,054
header-footer-elementor 212,182
elementskit-lite 209,363
bluehost-wordpress-plugin 191,408
gutenberg 163,525
gutenberg-core 160,943
cookie-notice 153,633
the-events-calendar 133,454
litespeed-cache 132,870
wpforms-lite 130,558
gtranslate 129,224
astra-sites 120,332
popup-maker 117,257
woocommerce-payments 113,813
tablepress 110,939
coblocks 100,525
honeypot 98,579
astra-addon 96,287
duracelltomi-google-tag-manager 94,758
wp-smushit 94,540
all-in-one-seo-pack 94,163
LayerSlider 92,505
bb-plugin 91,548
premium-addons-for-elementor 87,784
megamenu 87,690
akismet 86,772
mailchimp-for-wp 84,606
cleantalk-spam-protect 84,528
woocommerce-gateway-stripe 83,875
ml-slider 81,965
borlabs-cookie 80,562
fusion-builder 80,452
ewww-image-optimizer 79,824
wp-pagenavi 79,811
formidable 78,763

Top 50 Themes

Theme Count
hello-elementor 622,154
Divi 515,376
astra 427,781
flatsome 136,821
Avada 125,534
generatepress 122,038
pub 110,907
oceanwp 84,326
kadence 79,509
enfold 72,549
salient 67,305
twentytwentyfour 59,420
h4 56,888
twentyseventeen 56,800
bb-theme 55,720
betheme 52,419
cocoon-master 52,256
blocksy 51,289
dt-the7 46,628
twentytwentyfive 44,378
neve 39,825
Avada-Child-Theme 37,985
sydney 35,715
gox 33,650
woodmart 33,613
bridge 33,188
twentytwentyone 32,430
lightning 31,653
twentytwenty 30,348
swell 28,740
Impreza 26,771
bricks 26,340
twentytwentythree 24,219
Newspaper 23,785
voxel 23,104
twentytwentytwo 20,100
kubio 19,580
sinatra 19,425
uncode 19,303
epik-redesign 19,278
twentysixteen 18,417
storefront 18,092
pro 17,983
Total 14,866
extendable 14,714
yith-wonder 14,087
hello-theme-child-master 13,503
themify-ultra 13,124
yootheme 13,090
factory-templates-4 13,019