Notes from production
SEOCloudflareRedirect

Root → www: the 301 redirect

You want one official address. To you, pangaea.id and www.pangaea.id are the same site — but to a search engine they're two different sites, and any SEO credit (links, rankings) gets split between them. So we pick one canonical address and make the other permanently redirect to it.

For pangaea.id the canonical is www.pangaea.id — it's what the sitemap, the hreflang tags and every <link rel="canonical"> point at. The bare pangaea.id sends visitors there with a 301 ("moved permanently").

pangaea.idbare domain · root / apex301 · permanentwww.pangaea.idcanonical — the one URLCloudflare Pages serves it
A 301 tells browsers and Google "this moved for good" — so all SEO credit lands on one address, not two.

The steps

  1. Add both custom domains in the Pages project: www.pangaea.id (the real one) and pangaea.id.
  2. Create the Redirect Rule — Cloudflare → Rules → Redirect Rules → Create:
    • When incoming host equals pangaea.id
    • Then Static redirecthttps://www.pangaea.id + path, status 301, with "preserve query string" on.

That's it. The bare domain now 301s to www, paths and query strings intact.

Where this fits

This is the finishing touch on go-live, after the domain is on Cloudflare (Part 1) and the site ships via Pages (Part 2). The plain-English diary note is One address, not two →.

Sources

  1. Cloudflare — Single Redirects (Redirect Rules)
  2. Google Search — Redirects and Google Search