Web Server Rule Generator

Generate bounded nginx or Apache redirect and static-cache snippets from explicit entered choices.

Inputs stay on your device No sign-up Free to use
How this works

The tool runs in this browser. Your file or text is not uploaded to UseFreeTools. Check this tool's limits for anything it may save on your device.

Privacy details

Generate result controls

A literal root-relative ASCII path. No query, percent escapes, dot segments, regex or directive characters.

Used for redirects. Absolute HTTP(S), without credentials; the destination query replaces the original query.

Used for cache snippets; only this exact public static asset is matched.

Processed in your browser. Your inputs stay on this device.

Showing a generated example. Generate again for a new result.

How to use Web Server Rule Generator

  1. Select the server and supported rule type.
  2. Enter a literal path or the supported asset settings.
  3. Generate the snippet, review its context and test it before applying.

Example: Web Server Rule Generator

An exact redirect from /old to https://example.com/new.

You add
Server and snippet context: nginx Rule type: redirect Exact source or asset path: /old-page Redirect destination: https://example.com/new-page Redirect status: 301 Static asset cache days: 7
You get
Generated a snippet for the selected server context.

Options

Server context
Choose nginx or Apache and place the generated snippet only in the stated configuration context. Similar redirect tasks use different syntax on the two servers.
Literal path and query
Enter an exact supported path rather than a regex. The destination’s query replaces the original query, so check that behavior before using the redirect.

Supported inputs and limits

Finite nginx and Apache configuration contexts only. Literal paths and HTTP(S) destinations; injection characters and unsupported patterns are refused. Query handling is explicit. Static caching is for the named asset scope, not dynamic pages. Review context and test syntax before applying; no server settings are changed.

Where your input is processed

This tool processes your input in this browser. Your text and files are not uploaded to UseFreeTools. Check this tool's limits for anything it may save on your device.

Test an exact rule before broadening it

The generated snippet does not change any server. Review syntax in the intended version and context, test the matching path and a nonmatching path, and inspect the actual redirect status and destination. Static caching applies to the exact named public asset; it is not a policy for authenticated or dynamic pages.

Questions about Web Server Rule Generator

Will generating a rule change my server?

No. The result is a text snippet for you to review.

Can I paste a regular expression or directive?

No. These fields accept the documented literal choices and reject configuration injection.

Can static-cache rules be used for account pages?

No. They are scoped to the named static-asset case; dynamic or private responses need their own policy.

Project manager: Tony Hines · Content updated 4 October 2026 · Report a problem