.htaccess Redirect Generator

Generate Apache .htaccess redirect rules from a list of old and new URLs.

RewriteEngine On
Redirect 301 /old-page /new-page

Files never leave your device - everything is generated entirely in your browser.

Related tools

How it works

  1. 1

    Add one or more redirects

    An old path and its new destination.

  2. 2

    Choose permanent or temporary

    301 (permanent) or 302 (temporary).

  3. 3

    Copy into your .htaccess file

    On an Apache web server.

FAQ

Does this work on Nginx too?
No - .htaccess is specific to Apache. Use the Nginx Redirect Generator on this site for Nginx's own rewrite syntax.
Does this tool send my input anywhere?
No - the rules are generated entirely in your browser.

Tool4U.net — every tool runs in your browser. No file ever leaves your device unless the tool says so.

© 2026 Tool4U.net