Make a Webflow page the homepage with a URL rewrite, not a Worker

A single http_request_transform rule rewriting path / to /new-home swaps the homepage at the edge, runs before any Worker, and rolls back with one API call.

Zone

· Chapter

9

·

2

min read

The answer. Webflow's Data API can't set which page is the homepage; that flag is Designer-only. To serve a freshly built page at / without touching the old Home page, do it at the zone: one URL Rewrite (Transform Rule) in the http_request_transform phase, expression http.host eq "www.example.com" and http.request.uri.path eq "/", action rewrite uri.path to /new-home. The browser URL stays /; Webflow serves the new page. Transform rules run before Workers, so this works even with a third-party Worker on the route, and the failure mode is benign: the root keeps serving the old homepage. Reversal is deleting the rule.

The pattern.

// PUT /zones/{zone_id}/rulesets/phases/http_request_transform/entrypoint
{
  "rules": [
    {
      "description": "Serve /new-home at the root",
      "expression": "(http.host eq \"www.example.com\" and http.request.uri.path eq \"/\")",
      "action": "rewrite",
      "action_parameters": { "uri": { "path": { "value": "/new-home" } } },
      "enabled": true
    }
  ]
}
// Rollback: PUT the same entrypoint with "rules": []

The receipt. hesham.us went live on its second-generation redesign on 2026-08-25 with exactly this rule, / rewritten to /new-home on www. Twelve inner pages were moved onto their canonical slugs through the Webflow API in the same session; the homepage couldn't be, so the edge did it. The first attempt, on 2026-08-08, was a Worker that proxied the preview page at /, rewrote canonical and OG tags, and 301'd the preview URL: a codebase to maintain for one page, and it sat disabled after the owner pulled the homepage back for more polish the same day. The rule version needed no code. A stray SEO Worker that keeps reappearing on the same route never interfered, because the rewrite runs first.

Watch out.

  • The CMS can't see the rewrite: Webflow still emits the canonical for the page's real slug. Decide which URL you want indexed and check the tag.
  • Only proxied (orange-cloud) hostnames get rules. If the apex is DNS-only, the rewrite applies to www alone; pair it with an apex-to-www redirect.
  • PUT .../entrypoint replaces the whole phase. Read it first if other transform rules exist on the zone.

Related: r2-custom-domain-choose-once · production-canary-version-pinned-cutover