Generator Settings
Scenario
URL list → new URLs
Force HTTPS
www ↔ non-www
Whole domain migration
Trailing slash normalization
Pattern / regex rewrite
Directory → directory
Old URL → new URL
/old-page, /new-page /products/legacy-widget, /shop/widget /about-us.html, /about /blog/2019/announcement, https://example.com/news/announcement
One pair per line, separated by a comma, tab or pipe. Old paths may be absolute URLs — only the path is used for matching.
Old domain
New domain
Canonical host
Used for absolute targets and for the www rule.
Match (regex)
Replace with
Old directory
New directory
Preferred host form
Strip www
Force www
Trailing slash
Remove trailing slash
Add trailing slash
Real directories are excluded either way, otherwise Apache's own
DirectorySlash
fights the rule.
Status code
301 — Moved Permanently
302 — Found (temporary)
308 — Permanent, method preserved
307 — Temporary, method preserved
410 — Gone (no target)
Directive style
Recommended for this scenario
mod_rewrite — RewriteRule
mod_alias — Redirect / RedirectMatch
Options
Preserve query string
Adds the
QSA
flag so UTM tags survive the hop.
Absolute redirect targets
Prefix relative targets with
https://host
.
Case-insensitive matching
Adds
NC
. Useful after a move from Windows hosting.
Behind a proxy or load balancer
Tests
X-Forwarded-Proto
instead of
%{HTTPS}
.
Include IfModule guard
Wraps rules so a missing module cannot 500 the site.
Comments
Label each block so future edits are safe.
Generate
Reset
Generated Config
ready
.htaccess
Rule tester
Checks
Flags reference
.htaccess
Copy
Download
Rules run
in order
, top to bottom, and the file is re-read on every request. Put host-level rules (HTTPS, www) above page-level ones, and move the whole block into your vhost config once it is stable.
Test a URL against these rules