Plate № 22 · Routing · URL architecture
A pattern from the gf.cx specimen book
Memorable URL · canonical redirect
"Rather than writing vault.gf.cx/software/tailscale — do vault.gf.cx/tailscale and have a redirect manage the forwarding, with the correct canonical URL. It demonstrates ease-of-use, memorable URL structures with the correct canonical."
The problem
Good taxonomy buries good URLs. A page earns its place deep in a section — vault.gf.cx/software/tailscale/ is correct: it lives under /software/ with its siblings, and that path is what crawlers and the sitemap should treat as the one true home. But nobody types or remembers a three-segment path. Ask someone to "go to the tailscale page" and they'll try vault.gf.cx/tailscale first. Flatten the structure to win the memorable URL and you lose the taxonomy; keep the taxonomy and you lose the door people actually knock on.
The shape
You don't choose. Keep the content at its canonical deep path, and add a short, memorable vanity URL that 301-redirects to it. Two artefacts, one source of truth:
- The redirect (CF Pages
_redirects) forwards the memorable door to the real room — splat included so deep links survive:
# _redirects — memorable vanity → canonical deep path
/tailscale /software/tailscale/ 301
/tailscale/* /software/tailscale/:splat 301
- The canonical tag on the page keeps declaring the deep path as the truth, so the
301and the<link rel="canonical">agree and link-equity consolidates onto one URL:
<link rel="canonical" href="https://vault.gf.cx/software/tailscale/">
Now advertise the memorable one (vault.gf.cx/tailscale) everywhere a human reads — cross-links, social, print, "go to…" — and the structured one stays the canonical record. The redirect bounces the door to the room; the canonical tag tells the crawler which is the room.
Why 301, not 302
A vanity URL is a permanent promise, so use 301 (permanent): browsers and crawlers cache it and consolidate ranking signals onto the canonical target. Reserve 302 for genuinely temporary forwards where the destination is still settling (e.g. an IA mid-migration). Mixing them up either fails to pass equity (302 where you meant permanent) or hard-caches a move you'll want to undo (301 where you meant temporary).
When it breaks
- Canonical points at the vanity URL. If the page declares the short URL as canonical but the redirect sends the short URL away, you've told the crawler the canonical is a thing that 301s elsewhere — a contradiction. The canonical must be the URL that actually serves
200(the deep path). - Vanity collides with a real path.
/tailscalemust not also be a real directory. Vanity slugs live in a flat namespace at the root; keep them distinct from section names. - Forgetting the splat.
/tailscalealone redirects the bare page but/tailscale/anything404s. Add the/*→:splatline if the target can ever grow sub-pages.
Where it applies
- Any deep-but-frequently-shared page — a tool, a single report, a vendor record — that deserves a one-word door.
- QR / print / spoken contexts where the URL has to be typeable from memory (companion to the tag-router numeric + slug peers pattern, which solves the same memorable-vs-structured tension for asset tags).
- Cross-surface links: srvc.gf.cx links the homelab write-up as
vault.gf.cx/tailscale, not the deep path — the memorable form is the one that travels.
Reusable elements
The named, copyable pieces — lift any one without the others:
- The
_redirectsrule pair — bare slug + splat variant (/slugand/slug/*→:splat), both301. Two lines in the CF Pages_redirectsfile; works identically in Netlify redirects and Workers routing rules. - The
<link rel="canonical">tag — declared on the target page, pointing at the deep path that serves200. The301and the canonical must agree; a contradiction (canonical = the alias, alias 301s away) sends crawlers into a loop. - The memorable-alias convention — one-word slug at the root, flat namespace, kept distinct from real section directories. Advertise only the short form to humans; the canonical carries the structured path for crawlers and sitemaps.
Reference
- Source
- Dan, 2026-06-24 · the insight that you don't have to choose between taxonomy and memorability — the redirect decouples the door humans use from the URL crawlers index.
- In use / example
- vault.gf.cx/tailscale →
301→vault.gf.cx/software/tailscale/(canonical). First shipped 2026-06-24. The earlier/field-notes/<vendor>→/<vendor>/rules on the same surface are the temporary-302sibling of this pattern — same mechanism, opposite intent. - Reusable elements
_redirectsrule pair ·<link rel="canonical">on the target · flat root slug convention (listed above).- Origin
- First observed while cross-linking from srvc.gf.cx — the memorable short alias is the form that travels in prose and social; the deep path is the one that belongs in sitemaps.