Security headers

Clickjacking protection

Stop other sites from embedding your pages in a frame, with frame-ancestors or X-Frame-Options.

Why it matters

If your page can be framed, another site can place an invisible button over it and make users click something they did not intend.

This matters most for logged-in actions: payments, deletion, permission changes. One header blocks the whole class of attack.

How to fix it

  1. Send Content-Security-Policy: frame-ancestors 'none'

  2. If you must allow a partner to embed you, list only that origin

  3. Add X-Frame-Options: DENY only for old browsers

Prompt for an AI assistant

Copy the text below and paste it into an AI assistant.

You are the person improving this website. Check the item below and fix it if it applies to the site.

Item: Clickjacking protection
Summary: Stop other sites from embedding your pages in a frame, with frame-ancestors or X-Frame-Options.
Steps:
1. Send Content-Security-Policy: frame-ancestors 'none'
2. If you must allow a partner to embed you, list only that origin
3. Add X-Frame-Options: DENY only for old browsers
References:
- Clickjacking Defense (OWASP) (https://cheatsheetseries.owasp.org/cheatsheets/Clickjacking_Defense_Cheat_Sheet.html)
- X-Frame-Options (MDN) (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options)

Constraints:
- Keep the existing design and tone of voice.
- Show the file or section you changed and the suggested final wording.
- Do not decide ambiguous points alone; give options and a recommendation.
- Do not change anything outside the listed item.

Checked by

  • vuln

    Public exposure checks

Related checks

  • Content-Security-Policy (CSP)

    Send a Content-Security-Policy that limits where scripts, styles, and frames can come from, instead of allowing everything.

  • Other security headers

    Set X-Content-Type-Options, Referrer-Policy, Permissions-Policy, and COOP/CORP to close the small gaps browsers leave open by default.

References

Check your site now

Enter a URL and find what is missing before launch, for free.

Run audit