How to use this developer tool
- Choose the canonical host behavior.
- Enter source and destination redirects.
- Select performance and security blocks.
- Review the required modules and test on staging.
Generate Apache .htaccess rules for HTTPS redirects, host canonicalization, compression, caching, directory protection, and common security controls.
The generator assembles compatible Apache directives and flags common redirect-loop and missing-host risks.
Back up the existing file and test on staging. Invalid Apache directives can cause an HTTP 500 error.
Force HTTPS, redirect www to the canonical host, compress text assets, and redirect an old path to a new URL.
Use a mod_rewrite condition that checks HTTPS and redirects to the secure canonical URL.
Match only the non-canonical host and redirect once to the preferred host.
Add a specific RewriteRule from the old path to the new canonical path.
Use mod_deflate directives for compressible text-based content types.
The server may reject unsupported directives, missing modules, invalid syntax, or disallowed overrides.
| Feature | Module |
|---|---|
| Redirects | mod_rewrite |
| Compression | mod_deflate |
| Headers / security | mod_headers |