Free website audit in 60 seconds
Skip to content
Webmaster.ae
  • Loading…
Webmaster.ae
Free website auditSpeed, SEO, security and email, with a PDF report

Follow us

Runs in your browserFree · no sign-up

Content Security Policy generator

Tick the third-party services your site uses to build a Content-Security-Policy header that allows them and blocks everything else — ready to paste into Nginx, Apache or your framework.

Services
Live resultUpdates as you type

Press “Build CSP” to see the result here.

How do I use the content Security Policy generator?

Content Security Policy generator: frequently asked questions

What is a Content Security Policy?

A response header that tells browsers which sources of scripts, styles, images and frames your page may load, which limits the damage of cross-site scripting.

Should I start in report-only mode?

Yes. Report-only logs violations without blocking, so you can fix the policy before enforcing it.

Why does Google Tag Manager need extra rules?

GTM loads other scripts and can inject inline code. You may need nonces or hashes for custom HTML tags.

Is unsafe-inline dangerous?

For scripts, yes — avoid it. For styles it is a lower risk and often needed by frameworks.

How do I check my current headers?

Use our HTTP headers checker.

Does CSP affect SEO?

Not directly, but a broken policy can stop analytics or page features from working.

Is there an API for this tool?

Selected tools are available through a rate-limited public API. Contact us if you need higher volumes.

Is the content security policy generator free?

Yes. It is free with no sign-up and no usage limits for normal use.

Is my data sent to your servers?

No. This tool runs entirely in your browser, so what you type never leaves your device.

Does it work on my phone?

Yes. The tool works in any modern browser on iPhone, Android, tablet or computer.