Setup guide · 8 minutes · Advanced
Install llms.txt on Squarespace
Squarespace does not support uploading files to the site root directly. The cleanest workaround is to use Cloudflare in front of your Squarespace site.
00
Why this is harder
Squarespace's hosting model controls every URL on your domain — there is no way to drop a static file at /llms.txt from inside the Squarespace admin.
The fix is to put a Cloudflare Worker in front of your domain that serves /llms.txt from Cloudflare and proxies everything else to Squarespace.
01
Set up Cloudflare in front of Squarespace
- Sign up for a free Cloudflare account.
- Add your domain. Cloudflare will scan your DNS records.
- Update your domain registrar's nameservers to the ones Cloudflare provides (this can take up to 24 hours to propagate).
- In Squarespace, change your domain settings to use Squarespace's IP addresses behind Cloudflare. Squarespace docs cover the exact steps for your setup.
02
Add a Cloudflare Worker for /llms.txt
- In Cloudflare, go to Workers & Pages → Create.
- Name it
llms-txt. - Paste this code, replacing
YOUR_LLMS_TXT_CONTENTwith your actual file content:export default { async fetch(request) { const url = new URL(request.url); if (url.pathname === '/llms.txt') { return new Response(`YOUR_LLMS_TXT_CONTENT`, { headers: { 'content-type': 'text/markdown; charset=utf-8' } }); } return fetch(request); } } - Deploy. Then add a route:
yoursite.com/llms.txt→ this worker. - Visit
https://yoursite.com/llms.txtto confirm.
!!
Easier alternative
If Cloudflare feels like too much, you can also use a Squarespace Code Block to publish your llms.txt content as a regular page at /llms-txt (with a hyphen). It won't be at the root URL, but some AI systems will still find it via your sitemap. This is a fallback, not the recommended approach.