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

Plugin: wp-consent-api (Used by 48,055 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
s*i*l*g*c*e*s*a.com βœ… F 2026-05-15 11:35:39
s*i*l*g*c*e*c*n*e*.com βœ… F 2026-05-15 11:35:39
h*r*a*a*d*s*l*.com (WP 6.9.4) βœ… F 2026-05-15 11:32:53
f*i*a*e.c*.in (WP 6.9.4) βœ… F 2026-05-15 11:32:24
j*y*e*a*e*.com (WP 6.9.4) βœ… F 2026-05-15 11:31:55
j*y*e*u*m*r.com (WP 6.8.5) βœ… F 2026-05-15 11:31:54
p*r*.kr (WP 6.8.5) βœ… F 2026-05-15 11:31:17
c*s*b*y*r*.com (WP 6.9.4) βœ… F 2026-05-15 11:31:10
s*o*.l*m*n*i*e*c*u*i*e.com βœ… C 2026-05-15 11:29:32
l*r*-*u*t*m*d*a.com βœ… F 2026-05-15 11:29:07
z*d*r*e*t*b*a*.com βœ… F 2026-05-15 11:27:54
b*a*t*f*b*y.com (WP 6.9.4) βœ… F 2026-05-15 11:25:59
n*o*l*x.com (WP 6.9.4) βœ… F 2026-05-15 11:23:53
s*s*u*.org βœ… F 2026-05-15 11:23:39
o*t*p*s*f*w*r*.com βœ… D 2026-05-15 11:21:46
s*i*h*i*c*i*i*p*n*.com βœ… F 2026-05-15 11:20:42
s*i*g*u*m*t*h.com (WP 6.9.4) βœ… F 2026-05-15 11:20:41
s*i*g*u*m*t.com (WP 6.9.4) βœ… F 2026-05-15 11:20:41
m*l*i*a*r*v*s*t*.bg πŸ”“ F 2026-05-15 11:18:34
o*t*p*s*o*t*n*n*t*o*k.com (WP 6.9.4) βœ… F 2026-05-15 11:18:34
o*t*p*s*i*i*a*n*t*o*k.com βœ… F 2026-05-15 11:18:33
b*a*t*o*f*b*y.com (WP 6.9.4) βœ… F 2026-05-15 11:14:37
a*a*e*y*f*u*i*a*d*o*n*.com βœ… D 2026-05-15 11:14:21
c*r*s*n*t*d*.com βœ… F 2026-05-15 11:13:52
c*m*p*u*s.fr (WP 6.9.4) βœ… D 2026-05-15 11:13:36
a*s*e*c*o*.com (WP 6.9.4) βœ… F 2026-05-15 11:13:35
s*i*e*u*p*m*n*.com (WP 6.9.4) βœ… F 2026-05-15 11:10:50
l*r*i*s*r*i*e*.com βœ… D 2026-05-15 11:10:42
a*a*e*y*f*e*u*y*r*f*s*i*n*l*.com (WP 6.9.4) βœ… F 2026-05-15 11:10:35
t*r*n*e*t*n*.com (WP 6.9.4) βœ… D 2026-05-15 11:10:10
e*p*c*c*s*.ca βœ… F 2026-05-15 11:09:49
m*r*a*a*m*n*a*.com βœ… F 2026-05-15 11:09:03
j*y*e*y*o*k*d.com (WP 6.9.4) πŸ”“ F 2026-05-15 11:07:29
l*r*g*a*s.com βœ… F 2026-05-15 11:05:49
z*c*h*n*g.com (WP 6.9.4) βœ… F 2026-05-15 11:05:18
x*d*c*v*m*n*p*a*.com (WP 6.9.4) βœ… C 2026-05-15 11:04:36
l*n*s*y*n*a*d*b*r*.no βœ… F 2026-05-15 11:04:18
d*j*t*l*o*i.c*m.tr (WP 6.9.4) βœ… D 2026-05-15 11:03:44
t*r*m*m*b*o*.com βœ… F 2026-05-15 11:01:26
c*r*e*e*t*i*.com βœ… F 2026-05-15 10:58:31
e*u*p*m*d*r*.com βœ… F 2026-05-15 10:58:28
t*o*v*r*n*l*b.fr (WP 6.9.4) βœ… D 2026-05-15 10:57:08
b*a*i*g*o*n*.com βœ… F 2026-05-15 10:55:20
b*o*e*s*e*.w*e*g*n*p*w*r*d.com βœ… F 2026-05-15 10:54:04
r*n*g*o*i*g*e*v*c*.com βœ… D 2026-05-15 10:53:27
b*a*c*e*t*o*e*.com (WP 6.9.4) βœ… F 2026-05-15 10:50:37
b*a*t*n*u*n*r.com βœ… F 2026-05-15 10:50:36
e*u*p*e*t*r*v*d*r.com (WP 6.9.4) βœ… F 2026-05-15 10:50:31
e*u*p*e*t*i*n*.com βœ… F 2026-05-15 10:50:30
a*p*o*e*i*.c*.uk βœ… F 2026-05-15 10:49:24
c*r*u*c*r*u*.com βœ… F 2026-05-15 10:48:49
c*p*t*e*t*f*c*c*o*.com (WP 6.9.4) βœ… F 2026-05-15 10:47:44
r*c*a*e.m*i*o*u*i*n.com βœ… B 2026-05-15 10:47:09
d*v*s*u*a*c*s.be (WP 6.7.2) βœ… F 2026-05-15 10:47:09
c*s*.com (WP 6.9.4) βœ… D 2026-05-15 10:46:57
m*r*u*g*b*a*d*.com (WP 6.9.4) βœ… F 2026-05-15 10:46:37
a*p*o*i*e.c*.uk βœ… F 2026-05-15 10:44:41
m*s*u*s*o*c*s*e*s*i*e.o*g.uk βœ… D 2026-05-15 10:44:26
c*r*j*c*s*e*w*r*.com (WP 6.9.4) βœ… F 2026-05-15 10:43:12
c*p*r*u*t*s*.com (WP 6.9.4) βœ… F 2026-05-15 10:43:10
m*k*n*a*a*d*n.c*.uk (WP 6.9.4) βœ… D 2026-05-15 10:43:05
p*i*a*a*r*n.no βœ… F 2026-05-15 10:42:59
s*t*e*.w*e*g*n*p*w*r*d.com βœ… F 2026-05-15 10:38:44
d*s*r*t*s*e*e.es (WP 6.9.4) βœ… F 2026-05-15 10:38:25
d*e*e*t*e*-*r*c*-*e*.e*k*n*t*f*n.de (WP 6.9.4) βœ… F 2026-05-15 10:34:46
t*r*i*e.e*k*n*t*f*n.de (WP 6.9.4) βœ… F 2026-05-15 10:34:46
d*e*e*t*e*-*h*p.e*k*n*t*f*n.de (WP 6.9.4) βœ… F 2026-05-15 10:34:46
m*r*t*m*s*r*m*s.com βœ… F 2026-05-15 10:32:03
c*n*i*o*i*1*.my (WP 6.9.4) βœ… F 2026-05-15 10:30:08
i*r*o*o*e*a*e*t*c*.t*.it (WP 6.9.4) βœ… F 2026-05-15 10:27:48
e*b*t*d*s*a*s*n.es βœ… F 2026-05-15 10:26:45
s*r*n*h*l*f*n*i*g.us βœ… F 2026-05-15 10:25:29
c*a*t*-*i*e*e*p*r*e*c*.com (WP 6.9.4) βœ… F 2026-05-15 10:25:09
m*n*m*n*o.de (WP 6.9.4) βœ… C 2026-05-15 10:22:25
c*n*t.com (WP 6.9.4) βœ… F 2026-05-15 10:21:07
e*u*p*e*e*v*i.com βœ… F 2026-05-15 10:19:35
a*a*e*i*p*d*a*t.com βœ… F 2026-05-15 10:18:30
k*n*s*a*c*m*o*n*i*g.c*m.au βœ… F 2026-05-15 10:15:43
z*c*a*y*m*r*z.com βœ… F 2026-05-15 10:14:20
n*s*b*a.c*m.np βœ… F 2026-05-15 10:13:06
l*p*z*s*a*a*t*.com (WP 6.8.5) βœ… F 2026-05-15 10:12:18
a*s*u*t*r*.com βœ… A 2026-05-15 10:08:22
z*c*o*i*o*t*a*t*n*i*c.com (WP 6.9.4) βœ… F 2026-05-15 10:07:27
a*a*e*i*-*g*.com βœ… F 2026-05-15 10:03:49
b*a*c*t*o*n*o*.com (WP 6.9.4) βœ… F 2026-05-15 10:01:55
a*s*o*h*n.com βœ… F 2026-05-15 10:01:34
a*s*m*l*.com (WP 6.9.4) βœ… F 2026-05-15 10:01:33
e*u*n*x*-*r*s*n*e.com (WP 6.9.4) βœ… F 2026-05-15 10:01:20
h*r*w*r*h*a*e*.com (WP 6.9.4) βœ… F 2026-05-15 10:01:05
a*a*e*i*n*v*g*t*r*.com βœ… F 2026-05-15 09:55:26
n*c*a*t*i*i.ro βœ… D 2026-05-15 09:55:23
c*w*r*i*g*a*i*a.com (WP 6.9.4) βœ… F 2026-05-15 09:54:23
c*w*r*-*a*.com (WP 6.9.4) βœ… D 2026-05-15 09:54:23
s*i*a*c.com (WP 6.9.4) βœ… F 2026-05-15 09:54:22
l*p*u*i*o*t*n*.com βœ… F 2026-05-15 09:54:10
o*s*u*u*i*n*.com βœ… F 2026-05-15 09:51:49
n*o*o*t*o*r*.com (WP 6.9.4) βœ… F 2026-05-15 09:51:45
t*x*r*n.de (WP 6.9.4) πŸ”“ F 2026-05-15 09:50:53
s*i*t*g*e*l*m*.com (WP 6.9.4) βœ… C 2026-05-15 09:49:50
o*s*l*.com βœ… D 2026-05-15 09:48:47

Top 50 Plugins

Plugin Count
elementor 1,725,334
contact-form-7 1,690,003
elementor-pro 1,002,015
woocommerce 788,015
revslider 600,168
jetpack 453,897
js_composer 416,673
wp-rocket 317,194
essential-addons-for-elementor-lite 274,764
gravityforms 253,614
complianz-gdpr 234,415
instagram-feed 218,615
cookie-law-info 215,767
google-site-kit 209,071
sitepress-multilingual-cms 208,379
google-analytics-for-wordpress 208,205
header-footer-elementor 204,395
elementskit-lite 194,377
bluehost-wordpress-plugin 188,424
gutenberg 154,604
gutenberg-core 154,354
cookie-notice 135,495
wpforms-lite 129,473
the-events-calendar 124,590
gtranslate 121,051
litespeed-cache 120,809
astra-sites 120,704
popup-maker 112,543
woocommerce-payments 110,361
tablepress 98,659
coblocks 96,980
all-in-one-seo-pack 91,557
honeypot 90,732
astra-addon 90,516
wp-smushit 89,830
LayerSlider 89,097
bb-plugin 88,383
duracelltomi-google-tag-manager 87,562
akismet 83,663
premium-addons-for-elementor 83,549
cleantalk-spam-protect 82,090
mailchimp-for-wp 81,315
megamenu 80,359
woocommerce-gateway-stripe 79,472
fusion-builder 76,892
formidable 75,387
ewww-image-optimizer 74,259
smart-slider-3 73,376
gravityformsrecaptcha 73,348
wp-pagenavi 72,536

Top 50 Themes

Theme Count
hello-elementor 587,846
Divi 494,800
astra 411,852
Avada 120,231
flatsome 117,837
generatepress 111,357
pub 106,533
oceanwp 80,058
kadence 74,200
enfold 68,502
salient 64,549
h4 54,527
twentyseventeen 54,239
bb-theme 53,903
twentytwentyfour 52,582
cocoon-master 51,009
betheme 49,844
blocksy 47,774
dt-the7 43,808
twentytwentyfive 42,576
neve 37,451
Avada-Child-Theme 36,011
gox 32,281
twentytwentyone 32,119
bridge 31,947
woodmart 31,455
lightning 29,253
twentytwenty 29,235
swell 27,179
Impreza 24,888
bricks 24,441
twentytwentythree 24,438
Newspaper 21,733
twentytwentytwo 20,179
epik-redesign 19,424
uncode 18,070
pro 17,611
twentysixteen 17,544
storefront 17,237
sydney 16,295
extendable 16,203
voxel 14,466
Total 14,079
yith-wonder 13,972
themify-ultra 12,769
hello-theme-child-master 12,445
hestia 12,244
twentynineteen 12,116
yootheme 12,086
factory-templates-4 11,982