Cloudflare Error 1035: Fix an Invalid Rewritten Path

Cloudflare error 1035 means a URL rewrite generated an invalid path. Start with the matching rule and calculate its output for the failing address. A valid path must be nonempty and begin with a slash; Cloudflare also rejects a rewrite into its reserved /cdn-cgi/ namespace. After fixing the format, verify that WordPress actually serves the intended destination.

Guide reviewed: October 8, 2026. Interface labels may vary by version, account and device.

Check why the generated path is invalid

Generated output Likely issue Next check
An empty string No valid destination path Inspect optional or missing inputs
us/guides/ Missing initial slash Produce /us/guides/ if that is the intended destination
A /cdn-cgi/ destination Reserved Cloudflare namespace Choose the actual application path
A valid path that returns WordPress 404 Destination routing or content Check whether the target page exists

Inspect the generated path

Save the failing address and identify the matching URL rewrite rule. Look at the operation that changes the path, then work through its value or expression using the failing request. The original address may be valid even when the generated destination is not.

Cloudflare’s documentation says the rewritten path should be nonempty and begin with a slash. A common illustration is adding a country label in front of an existing path. Producing us/guides/ leaves out the initial slash; producing /us/guides/ gives the path the expected beginning. Whether WordPress has a page at that destination is a separate question.

This distinction matters during testing. Correcting the path format can remove 1035 and reveal a normal WordPress 404 if the destination does not exist. That is progress in identifying the request, but it still requires a destination that makes sense for your site.

Keep a full address separate from a path

Describe the desired visitor experience: should the browser address change, or should the request be mapped internally? A path such as /new-guide/ and a full URL containing a hostname serve different configuration purposes. Confirm the Cloudflare feature before adapting the expression; use an internal rewrite only when keeping the original visible address is intended.

A path rewrite field should be reviewed as a path, rather than as a place to paste whatever address you have available. If the goal involves a different hostname or a browser redirect, first check which Cloudflare feature supports that purpose. A path-only operation cannot be assumed to perform every kind of URL change.

For instance, a site owner moving an old article to a new location may want visitors to see the new address. Another owner may want an internal mapping while keeping the visible address. Those are different outcomes, and choosing the right feature makes the configuration easier to understand.

Before changing the rule, write down the intended incoming path and destination. A simple pair such as /old-guide/ to /new-guide/ gives the administrator a clear target without mixing a hostname change into the same discussion.

Check reserved destinations and unexpected inputs

For a dynamic expression, record the result for the root path, an ordinary article, and an input with any optional component absent. Ensure the resulting path remains nonempty, retains its initial slash, and preserves the intended remainder. Change the relevant path operation with a recorded rollback option.

Cloudflare also documents 1035 when a URL rewrite targets a path under /cdn-cgi/. That namespace is not an appropriate destination for an ordinary WordPress article rewrite. Review the generated result if the expression can produce such a path.

Dynamic rules need examples beyond a single successful request. Include the homepage path, the affected article path, and any optional input used by the expression. An input that is empty or formatted differently can change the generated destination in a way that is easy to overlook.

Keep the original rule configuration before adjusting it. If several operations appear together, change only the one responsible for the invalid path. This lets you compare the result without introducing unrelated changes to headers or query strings.

Verify the page that visitors actually receive

Once the revised path is valid, open the original address and confirm that the intended WordPress content appears. The disappearance of the Cloudflare error is only one part of the result. A different article or an empty page would still be a problem for visitors.

Check a second address covered by the rule and one outside its scope. If the rewrite applies to a family of paths, use examples with different endings so that a working prefix does not hide an incorrect remainder.

For a rule affecting forms or account pages, test the relevant workflow with harmless data. Avoid broad changes to every request just to repair one article path; a narrow condition is easier to maintain when the original need is narrow.

If 1035 continues, share the rule identifier, sanitized expression, original address, and generated path with the administrator. Those details reveal whether the output is empty, missing its starting slash, or entering a reserved namespace. They also make it easier to distinguish a rewrite-format issue from a later WordPress page-routing problem.

Reference: Cloudflare error 1035 documentation.

Successful repair versus a new routing error

Removing 1035 confirms that the rewrite output passed that check. It does not confirm the destination exists. Open the original address, inspect the page content, and test a second matching path and an unrelated path. If the result is now a WordPress 404, investigate the destination using the WordPress 404 guide.

Leave a Comment