Azlaan Electric AC Solar Center — Solar, CCTV, AC & electrical work, Faisalabad Call: 0300-8987448

CSP Security Header Builder

Pick sources for each directive below. Your Content-Security-Policy is generated live, with server snippets for Apache and Nginx.

Preset:

Strict: only your own domain, no frames, no plugins — strongest protection.

Security warning
    Note: frame-ancestors and reporting directives are ignored inside a <meta> tag. Use the real HTTP header on your server for full protection.

    HTTP header

    
                    

    Meta tag version

    
                    

    Apache (.htaccess)

    
                    

    Nginx snippet

    
                    
    How to read a directive
    • 'self' — only your own domain (same scheme and host).
    • 'none' — blocks everything for that directive.
    • https: — any source over HTTPS.
    • data: / blob: — inline data URLs, useful for images.
    • 'unsafe-inline' — allows inline scripts and styles; weakens XSS protection.
    • 'unsafe-eval' — allows eval() and similar; avoid unless a library truly needs it.