// Jason's Plugins For Carrd

Multi-page Carrd

Carrd is a single-page builder. Sections are linked with hash URLs like https://mydomain.com/#blog - not real subdirectory paths like /blog. This provided code turns a Carrd site into something that feels multi-page. Each section gets its own subdirectory URL that visitors can bookmark, share, and open directly./blog → shows the #blog section; URL stays /blog
#blog → same content; URL normalizes to /blog
Examples: writingemoji.com/blog | writingemoji.com/#blog
Just paste the provided code into your Cloudflare dashboard.
Tutorial here →

Tutorial

Multi-page Carrd (Cloudflare Worker)
==========================================
Multi-page Carrd v1 (Cloudflare Worker)Carrd is a single-page builder. Sections are linked with hash URLs like https://mydomain.com/#blog — not real subdirectory paths like /blog.This code (for a Cloudflare Worker) turns a Carrd site into something that feels multi-page: each section gets its own subdirectory URL that visitors can bookmark, share, and open directly.- https://mydomain.com/blog → shows the #blog section; URL stays /blog
- https://mydomain.com/#blog → same content; URL normalizes to /blog
No npm or Wrangler. Paste multi-page-carrd.js into the Cloudflare dashboard.This is the original v1 release — clean URLs only. It does not inject per-section <title>, <meta name="description">, or <link rel="canonical">.INSTALLATION SERVICE:
But if this is too much work, I can set everything up for you, at a fee of US$500. Contact me →
------------------------------------------------How it worksCarrd still hosts one HTML page on your custom domain. Cloudflare sits in front (proxied DNS → Carrd’s A/CNAME records). The Worker:1. Serves Carrd’s / HTML for paths like /blog
2. Injects a small browser script that opens the matching Carrd section (#blog) and keeps the clean path in the address bar
Hash fragments (#…) never reach the server — section activation and URL cleanup happen in the browser.Title, description, and canonical tags stay exactly as Carrd published them on every path.------------------------------------------------Requirements- A Carrd site on a custom domain
- A Cloudflare account (Free plan is enough)
- Ability to change the domain’s nameservers to Cloudflare
- Section names in Carrd (set on section breaks) that match your paths — e.g. section blog → /blog
------------------------------------------------Setup1. Put Cloudflare in front of Carrd1. Cloudflare Dashboard → Add a site → enter your domain (e.g. mydomain.com)
2. Keep the DNS records Carrd gave you (A for @, CNAME for www, etc.)
3. Set those records to Proxied (orange cloud) — required for Workers to run
4. Update nameservers at your registrar to the ones Cloudflare provides
5. Wait until the zone status is Active
6. SSL/TLS → set encryption mode to Full
Confirm the site still loads through Cloudflare before adding the Worker. In DevTools → Network, responses should show server: cloudflare and a cf-ray header.---2. Create the Worker1. Workers & Pages → Create → Create Worker (use the empty / Hello World starter — not GitHub import or a template)
2. Name it (e.g. multi-page-carrd) → Deploy
3. Edit code → delete the starter → paste the full contents of multi-page-carrd-v1.js
4. Deploy
There is no file upload — pasting into the dashboard editor is the intended workflow.---3. Attach a Route (not Custom domain)Worker → Settings → Domains & Routes → Add → Route:- Route: mydomain.com/*
- Also www.mydomain.com/* if you use www
Repeat for each domain. Use Route, not Custom domain. If you try Custom domain, Cloudflare may error with “Hostname already has externally managed DNS records” — that’s expected. Keep Carrd’s A/CNAME records; do not delete them.In Workers & Pages → your Worker → Settings → Domains & Routes, open each route (mydomain.com/*, www.mydomain.com/*). Make sure Failure Mode is explicitly set to Fail open (proceed) so your site stays up even if the Worker errors or is disabled (perhaps due to exceeding 100,000 daily requests).---4. VerifyReplace mydomain.com and blog with your domain and Carrd section name.First, confirm the hash URL works on Carrd:https://mydomain.com/#blog → should open the blog sectionThen test clean paths:• URL - Expected
https://mydomain.com/ - Home (unchanged)
• https://mydomain.com/blog - #blog content; URL bar stays /blog
• https://mydomain.com/#blog - Same content; URL bar updates to /blog
Worker is running when DevTools → Network shows:- x-multi-page-carrd: blog (or your section name)
- server: cloudflare
- Status 200 (not Carrd 404)
In Carrd, section links can stay as #blog — clicks are rewritten to /blog.------------------------------------------------Notes- Same-zone fetch() would re-invoke the Worker and loop. The script sets a hop header (X-Carrd-Clean-Urls) on the origin subrequest; the second pass forwards to Carrd and skips rewriting.
- This does not require a *.carrd.co URL. It doesn't work on a *.carrd.co URL. Origin is your custom domain via Cloudflare → Carrd.
- Path segments must match Carrd section names exactly (lowercase, letters, numbers, hyphens).
- Forms and third-party embeds usually still work; test after deploy.
- All pages share Carrd’s single <title> and meta description. Search engines and social previews will not see per-section SEO unless you upgrade to the current Worker (README.md).
------------------------------------------------Troubleshooting[Issue → Fix]
- /blog returns Carrd 404, server: Apache, no x-multi-page-carrd
→ DNS records are DNS only (gray cloud) or the Worker Route is missing. Orange-cloud DNS and add mydomain.com/* as a Route
- “Hostname already has externally managed DNS records”
→ Use Route, not Custom domain. Keep Carrd’s DNS records
- /blog redirects to /
→ Redeploy the latest multi-page-carrd-v1.js (older versions treated a cleared hash as home)
- Section doesn’t open
→ Confirm https://mydomain.com/#blog works first; the path name must match the Carrd section name exactly
- www works but apex doesn’t (or vice versa) → Add a separate Route for each hostname- Infinite loop / error 1101 → Confirm the hop-header pass-through is present in the pasted code- SSL errors → Use SSL/TLS mode Full (not Flexible)------------------------------------------------License:
MIT
------------------------------------------------"DONE-FOR-YOU" INSTALLATION SERVICE
If this is too much work, I can set everything up for you, at a fee of US$500.
Contact me →

← Back

Contact

I can help set this up for you, at a developer fee of US$500.Set up once, use forever for ALL your sites on Cloudflare domains. * subject to your Cloudflare Worker limitsIncludes additional features for SEO:
– sitemap
– meta tags for each /page's title, description
– page canonical link
Reach out to find out more. Or just contact me (Jason) over at Telegram.