Nginx Redirect Builder
Generate an exact-match Nginx permanent redirect.
Read the guideRun the tool
The calculation runs in your browser. This tool does not send your input to JVR Software.
More information
Back to the toolWhat it is and when to use it
Nginx Redirect Builder produces a starting config snippet for moving a known route to a new URL. It is useful for documentation, path migrations and straightforward canonical path decisions on an Nginx site you maintain.
How it works
Nginx picks the appropriate server and location based on the request. A redirect returned there gives the client an HTTP status and target address. Where the snippet is placed matters, because surrounding location rules and host matching affect whether the request reaches it.
How to use it
- Enter the old route and new location.
- Read the generated exact-location rule and its permanent 301. Adapt the status in staging if you need a temporary test.
- Place the rule in the intended server block, validate the configuration and check the response from the client.
Worked example
Suppose /support-old should forward to https://example.com/help. Test /support-old first, then /support-old/ and /support-old/contact. Decide separately whether those last two addresses should match, since an exact location rule and a location prefix treat those paths differently.
Reading the result
Review the final URL as well as the redirect itself. An apparently correct first hop can still lead to another redirect or an error. Check that the right hostname and scheme take effect behind any reverse proxy, and make a separate decision about preserving query strings where needed.
Common mistakes and limits
The generator cannot predict precedence in your existing Nginx configuration. Verify with the server’s config test and staged requests before reloading production. Depending on your application, an HTTP redirect status that preserves the request method may be required for routes used by clients beyond ordinary page navigation.
