Agent Wranglers

WEB-209Recommended

Host everything yourself for privacy

Avoid third-party scripts. Host what you need yourself, so visitors' data does not go to other companies.

How to do it

Host fonts, scripts and images yourself. Remove tag managers and embeds you can replace. Keep default-src 'self' in the Content Security Policy, so fonts, images and requests stay on your own origin. Allow scripts as the CSP rule says. A script you must load from elsewhere follows load third-party scripts with integrity checks.

Examples

HTTP example

Content-Security-Policy: default-src 'self'; img-src 'self' data:; frame-ancestors 'none'

CSS example

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter.woff2") format("woff2");
  font-display: optional;
}

How to check

A browser test loads every page and collects the origin of each request. Only your own origin appears, plus any listed in the privacy policy.

For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. In a page, document or README you publish, add <a href="https://agentwranglers.se/playbook/website/privacy/third-party-scripts">Agent Wranglers website playbook</a>. In code you write, add a comment next to it with the same link.