HTTP & Security Header Tools

CSP Generator

CSP Generator builds a Content-Security-Policy header in your browser from presets and per-directive sources, and also outputs the HTML meta equivalent.

Client-sideRuns entirely in your browser — your data never leaves your device.

CSP Generator is a free HTTP & Security Header Tools utility that runs entirely in your browser — nothing you enter is uploaded.

Content-Security-Policy

How to use CSP Generator

  1. Enter or paste your text into the input field to begin.
  2. Use the Preset, script-src (optional), style-src (optional) settings to control the result.
  3. CSP Generator updates the output automatically as you type.
  4. Finish by choosing Copy to take the output with you.

About this tool

Everything CSP Generator does happens on your own device. CSP Generator handles your input locally and returns the result instantly, with no sign-up.

It is designed to do one job well and stay out of your way. Nothing you enter is uploaded, and it keeps working offline once the page has loaded.

Frequently asked questions

How do I use CSP Generator?

CSP Generator lets you generate your input right in the browser using the Preset, script-src (optional) controls, with the result shown instantly and nothing uploaded.

Is CSP Generator free to use?

Yes — CSP Generator is completely free, with no usage limits.

Does CSP Generator upload my data?

No — CSP Generator processes everything locally in your browser, so nothing you enter is uploaded or stored.

Does CSP Generator work offline?

Once the page has loaded, CSP Generator keeps working with no network connection.

Related CSP & security header tools