Redirects
A redirect sends visitors from one address to another — the easiest kind of rule.
Use a redirect when you:
- Moved or renamed a page, keep old links working.
- Want
www.example.comandexample.comin one place. - Move everyone from
http://tohttps://. - Run a short link pointing elsewhere.
Address bar shouldn’t change? Use a rewrite instead.
Create a redirect
Section titled “Create a redirect”- Go to Rules → Add Rule → Redirect.
- When — addresses to match, e.g.
/old-page. - Then — a full URL (
https://example.com/new-page) or a path. - Pick the type (below) and Save.
Temporary vs. permanent
Section titled “Temporary vs. permanent”| Type | Code | Use it when |
|---|---|---|
| Temporary | 302 | Sale, maintenance, experiment, or still testing. |
| Permanent | 301 | Moved for good; search engines update links. |
| Temporary, keep method | 307 | Like 302, but POST stays POST. Forms, APIs. |
| Permanent, keep method | 308 | Like 301, but POST stays POST. |
Keep path and query
Section titled “Keep path and query”- Keep the query string — appends
?utm_source=xto the target. On by default. - Keep the path — appends the original path: turns one rule into a
whole-site move,
example.com/*→newsite.com/*. Leave off for a single-page target.
Common examples
Section titled “Common examples”Force HTTPS —
http://→https://, permanent.
wwwto plain domain —www.example.com→example.com, permanent, keep the path.
Old page to new page —
/about-us→/about, permanent.
www redirects need a proxied record
Section titled “www redirects need a proxied record”A www ↔ plain-domain redirect needs a proxied DNS record for www.
Creating either canonical redirect sets it up. If nsin flags www as
unproxied, switch it or the redirect won’t fire. See
Managing DNS Records.
Common questions
Section titled “Common questions”My redirect loops forever. When and Then target each other. Exclude the target path.
I changed a redirect but still see the old behavior. Browsers cache permanent redirects — test in private.
Two redirects match. The one higher in the list wins. See Rules Overview.