Codo Content Security Policy
Just Content-Security-Policy, not a security suite. Starts in Report-Only, with draft policies, built-in violation reports and page scanning.
Choix solide
Codo Content Security Policy is a solid plugin choice in 2026, with a few things worth checking first. Was last updated 2 weeks ago, and scores 64/100 on our health check.
- Développé activement — Dernière mise à jour il y a 2 semaines
- Testé avec le dernier WordPress (7.1)
- Petite base d'utilisateurs (<10 installations actives)
- Très peu de critiques jusqu'à présent
Comment s'accumule-t-il ?
Côte à côte sur les installations, les mises à jour, les évaluations et le supportTéléchargements quotidiens
Les pics de téléchargement suivent généralement une nouvelle version - chaque site qui met à jour automatiquement compte comme un téléchargement.
Classements
Where Codo Content Security Policy stands todayWordPress.org Classements de recherche
Position en direct dans la recherche de plugins, Top 100| Mot-clé | Position |
|---|---|
| clickjacking | #29 |
| content security policy | >100 |
| csp | #83 |
| En-têtes de sécurité | >100 |
| xss | >100 |
About Codo Content Security Policy
À partir du Lisez-moi officiel · v1.1.0Description
A Content Security Policy tells browsers which scripts, styles, fonts, images, frames and form targets your pages may use. Anything else is blocked, which stops a whole class of attacks: scripts injected from other hosts, data sent to attackers’ servers, forms hijacked to post elsewhere, and your site being framed for clickjacking.
The hard part is building a policy without breaking the site. Codo Content Security Policy is designed around that.
It is built by Codo Digital, a UK web development and managed hosting company, and is the policy plugin we use on our own clients’ sites. Everything is free. There is no Pro version, no upsell, no account to create and no tracking.
Safe by default
- Starts in Report-Only. On activation the policy is sent as
Content-Security-Policy-Report-Only: nothing is blocked, and browsers report what would be. When the reports are clean, enforce it with one button. - A sensible starting policy for WordPress: same-site resources, core’s emoji images and emoji-test worker, Gravatar, no plugins (
object-src 'none'), no<base>hijacking, forms posting only to your site, and no framing by other sites. - The admin area is never covered. Even a broken enforced policy cannot lock you out of the screen that fixes it. There is also a
wp-config.phpkill switch.
Changing an enforced policy without breaking it
- Adding a source applies straight away. Adding to an allowlist can only allow more, so it cannot break anything.
- Tightening goes into a draft. Removing a source, adding a hash, or anything else that could block something loading today is held in a draft. The draft is sent as a Report-Only policy alongside the enforced one, so real visitors’ browsers test it without anything being blocked. When its reports are clean, promote it.
- New directives inherit. Creating
frame-srcfor YouTube would normally stop it falling back todefault-src, silently blocking your own iframes. The plugin copies the inherited sources across first.
Violation reports, built for slow sites
- Reports are answered before your theme loads, with an empty
204response. - Chromium browsers batch reports, so one page view is usually one request.
- Identical reports are counted, not stored again, even when the same thing is blocked on every page. At most 500 different violations are kept, for 30 days. If the table fills up, the Reports tab says so rather than looking clean.
- Processing is rate-limited, and collection runs for a set period (1, 7 or 30 days) and then switches itself off.
- Each report has an Allow button. Anyone can send a report, so nothing is ever allowed automatically.
- You can send reports to an external collector (Sentry, report-uri.com and so on) instead.
Scanning
- After you publish or update content, the page is fetched in the background as a logged-out visitor. Every script, stylesheet, font, image, iframe, media file and form target is checked against the policy, including the fonts and images inside your site’s own stylesheets. Stylesheets hosted elsewhere are never downloaded; for Google Fonts and Bunny Fonts the font host is filled in automatically.
- Problems show in the posts list, in the editor, and on the Scan tab, each with an Allow button.
- You can scan any page, the login page, or your 20 most recently updated pages.
- Scans also warn when the server, a CDN or another plugin sends a second policy, and when the headers grow past 4 KB, which breaks NGINX’s default FastCGI buffers.
- When a scan finds rules from another policy, you can import them alongside your own. Each rule is reviewed first: safe ones are ticked, risky ones need your decision, and unsafe ones are refused. Nothing is removed or duplicated.
Also
- Login page policy: wp-login.php gets its own rules, because reCAPTCHA, Turnstile and two-factor plugins load scripts there.
- Presets for common services: Google Analytics, Tag Manager, Fonts and Maps, reCAPTCHA, Turnstile, YouTube, Vimeo, Stripe, PayPal, Gravatar, Jetpack, Meta Pixel, Hotjar and Microsoft Clarity.
- Page builders keep working: no policy is sent in the Customizer preview or in Elementor, Divi, Beaver Builder, Bricks, Oxygen, WPBakery, Thrive, Brizy or Avada’s front-end editors, for users who can edit.
- Page caches are purged when the policy changes, so visitors get the new headers. Supported: WP Super Cache, W3 Total Cache, WP Rocket, LiteSpeed Cache, Nginx Helper, SiteGround Optimizer, WP-Optimize and Breeze.
- Multisite: network defaults that every site adds to.
- Post embeds keep working:
frame-ancestorsis left out of/embed/pages, which exist to be framed by other sites. - No JavaScript on the settings screen, so it cannot conflict with other plugins’ admin scripts.
Why ‘unsafe-inline’ is in the starting policy
Almost every WordPress site prints inline scripts (core, themes and plugins all do). The strict alternatives don’t fit most sites: nonces don’t survive full-page caching, and hashes break whenever an inline script changes. So the starting policy keeps 'unsafe-inline' for scripts and styles and works as an allowlist. It still blocks scripts from hosts you haven’t listed, eval, plugins, <base> hijacking, form hijacking, data exfiltration through connect-src, and clickjacking.
If your site can do without inline scripts, remove 'unsafe-inline' from script-src. The change goes through a draft first, and the Reports tab shows exactly what breaks.
For hosts and agencies: configuration in wp-config.php
define( 'CODO_CSP_DISABLE', true ); // Send no policy headers at all.
define( 'CODO_CSP_MODE', 'enforce' ); // Or 'report-only'.
define( 'CODO_CSP_REPORT_URI', 'https://example.report-uri.com/r/d/csp/enforce' );
define( 'CODO_CSP_LOGIN', false ); // No policy on wp-login.php.
Constants override the settings screen and show as read-only there.
Pour les développeurs
codo_csp_headersfilter: change the headers before they are sent. Receivesarray( name => array( values ) )and the context (siteorlogin).codo_csp_skip_requestfilter: return true to send no policy on a front-end request.codo_csp_presetsfilter: add or change presets.codo_csp_default_rulesfilter: change the policy a site starts with.codo_csp_capabilityfilter: change who can manage the policy (defaultmanage_options).codo_csp_report_rate_limitfilter: report requests processed per minute (default 120).codo_csp_max_report_rowsfilter: different violations kept (default 500).codo_csp_policy_changedaction: fires when a policy changes. Hook in to purge a cache or CDN the plugin doesn’t know about.codo_csp_purge_cachesaction: fires after the plugin purges page caches.codo_csp_mode_changedaction: fires when switching between Report-Only and enforced.
Source, issues and tests: github.com/Codo-Digital-Ltd/codo-content-security-policy.
Services externes
The plugin does not contact any third-party service, collect usage data or track visitors or administrators.
- Scanning stays on your site: scans request pages and stylesheets from your own site only (a loopback request, like Site Health makes), and refuse redirects to other sites. Stylesheets hosted elsewhere are never downloaded.
- Presets are host names, not downloads: presets such as Stripe, Google Fonts or reCAPTCHA only add those services’ host names to the policy your site sends, so your visitors’ browsers are allowed to load what your theme and plugins already use. This plugin never loads anything from them.
- External report collector (optional, off by default): if you enter a collector URL (or define
CODO_CSP_REPORT_URI), your visitors’ browsers send violation reports straight to that URL instead of your own site. Each report holds the page URL, the blocked URL, the directive and, depending on the browser, a short sample of the blocked code. Nothing is sent anywhere else if the setting is left empty. The terms and privacy policy are those of whoever runs the URL you choose.
Installation
- Install from Plugins > Add New, or upload the
codo-content-security-policyfolder to/wp-content/plugins/. - Activate the plugin. The policy starts in Report-Only and collects reports for 7 days.
- Go to Settings > Content Security Policy. Add presets for the services your site uses, and use the Scan tab to check your main pages.
- Browse the site, then check the Reports tab. Allow what you recognise.
- When reports stop appearing, click Enforce the policy.
Journal de modifications
Import rules found by a scan, with a safety review. New rules can no longer allow whole shared domains or public CDNs for scripts; existing rules keep working and are flagged.
1.1.0
- New: import rules from another policy found by a scan, with a safety review of every rule. Existing rules are kept and never duplicated.
- Changed: new rules can no longer allow a whole shared domain (such as *.cloudfront.net), or a whole public CDN (such as cdn.jsdelivr.net) for scripts. Rules you already have keep working and are flagged on the policy screen.
- Changed: when a whole host would be refused, a scan’s Allow button offers the exact file instead.
1.0.0
- First release: front-end and login policies, Report-Only by default, enforced mode with draft policies, built-in aggregated violation reports, page scanning after publishing, presets, page builder exclusions, cache purging, multisite network defaults and wp-config.php constants.
Pour les développeurs
Est-ce votre plugin ? Montrez les chiffres.
Ajoutez un badge en direct à votre site, docs ou github readme. Il se met à jour par lui-même - aucun compte n'est nécessaire.
Best Codo Content Security Policy alternatives
All clickjacking plugins →FAQ
Codo Content Security Policy: quick answers
Réponses directes, extraites des données en direct WordPress.org.
Source : WordPress.org
Is Codo Content Security Policy free?
Yes. Codo Content Security Policy is free to download and use from the official WordPress.org plugin directory.
Is Codo Content Security Policy safe to use in 2026?
Codo Content Security Policy is a solid plugin choice in 2026, with a few things worth checking first. Was last updated 2 weeks ago, and scores 64/100 on our health check.
How many websites use Codo Content Security Policy?
Codo Content Security Policy is active on <10 WordPress websites and has been downloaded 357 times since it launched in November 2026. It was downloaded 360 times in the last 30 days.
Does Codo Content Security Policy work with WordPress 7.1?
Yes. The developer has tested Codo Content Security Policy up to WordPress 7.1.5, the latest release. It requires WordPress 6.2 or newer.
What PHP version does Codo Content Security Policy need?
Codo Content Security Policy requires PHP 7.4 or higher. Most hosts run PHP 8.x today, so it works on any modern WordPress hosting.
When was Codo Content Security Policy last updated?
The latest version, 1.1.0, was released on November 7, 2026 (2 weeks ago).
Who makes Codo Content Security Policy?
Codo Content Security Policy is developed and maintained by Codo Digital Ltd.
What are the best alternatives to Codo Content Security Policy?
The most popular alternatives to Codo Content Security Policy are Headers Security Advanced &… (90K+ installs), WP Anti-Clickjack (3K+ installs) and HTTP Security Header (1K+ installs).
Propulsé par PageForge
Un modèle et une feuille de calcul. Une vraie page pour chaque recherche.
PageForge transforme chaque ligne d'un CSV en une page WordPress avec son propre titre, URL, SEO et schéma, construit sur la mise en page que vous Déjà conçu. Gratuit sur WordPress.org.
- CSV et XLSX, plus Google Sheets sur les professionnels et les entreprises
- Son propre titre, URL, SEO champs et schéma pour chaque page
- Fonctionne avec l'éditeur de blocs, Elementor, Divi et Avada
- Gratuit sur WordPress.org, pas de carte de crédit
