Nginx Redirect Generator

Turn a list of old and new URL paths into nginx location redirect rules (301/302). Runs locally in your browser.

About this tool

Enter one rule per line as: /old-path /new-path [301|302]. Each line becomes an exact-match nginx location block with a return redirect. Defaults to 301 permanent. Paste the output inside your server block and reload nginx.

Related: JSON Formatter & Validator · Base64 Encode & Decode · URL Encoder & Decoder · SHA-256 / SHA-1 Hash Generator · Unix Timestamp Converter