CSP Header Generator — Content Security Policy Builder
Build Content-Security-Policy headers with an interactive directive editor. Presets for strict, moderate, and permissive policies.
Presets
Directives
Additional Directives
upgrade-insecure-requestsInstructs browsers to upgrade HTTP requests to HTTPS
block-all-mixed-contentPrevents loading any mixed content (HTTP on HTTPS pages)
# Configure directives above to generate your CSP header...
What is a CSP Generator?
A Content-Security-Policy generator helps you build CSP headers that protect your website from XSS, data injection, and other code injection attacks.
Notez cet outil
4.8 / 5 · 75 avis
Plus d'outils
🏷️Générateur de Balises Meta.ht.htaccess GeneratorNXNginx Config Generator🤖Générateur Robots.txtRestez informé
Recevez des astuces dev et les nouveaux outils chaque semaine.
Pas de spam. Désabonnez-vous à tout moment.
Enjoy these free tools?
☕Buy Me a CoffeeHow to Use
- Select a preset or start from scratch
- Configure each directive
- Add trusted sources
- Copy the CSP header
Use Cases
- Preventing XSS attacks
- Meeting security compliance
- Configuring Content-Security-Policy
- Testing CSP rules