Bulk redirect documentation wrong?

What is the name of the domain?

What is the error number?

What is the error message?

What is the issue you’re encountering

Documentation

What steps have you taken to resolve the issue?

Please confirm this to me. The Bulk Redirect documentation seems to be wrong?

Subpath matching says this:
With this configuration and Subpath matching enabled, an incoming request to example.com/foo/bar will be redirected to https://example.com/qux/bar
However this is not true. This is only true if Preserve path suffix is also set to true, which is not the default value. On the default settings, example.com/foo/bar will redirect to example.com/qux.

What are the steps to reproduce the issue?

Thanks for bringing this up! You’ve identified a discrepancy between how the UI and API handle the default value of Preserve path suffix in Bulk Redirects.

  • In the Cloudflare Dashboard, when creating a bulk redirect list entry, no options are selected by default. However, the UI explicitly sends "preserve_path_suffix": false unless manually enabled.

  • In contrast, when creating a bulk redirect list entry via API, if preserve_path_suffix is omitted, the backend interprets it as true, meaning the path suffix is preserved.

This means that:

  • If you create a Bulk Redirect through the UI and don’t enable Preserve path suffix, example.com/foo/bar will redirect to example.com/qux.

  • If you create the same bulk redirect list entry via API and omit preserve_path_suffix, example.com/foo/bar will redirect to example.com/qux/bar.

We recognise this inconsistency and will check if we can adjust the dashboard behaviour soon to align it with the API. Thanks again for reporting this! Let us know if you have any further questions.

Thanks for the quick explanation!

BTW, preserve_path_suffix really should be the default, as I understand SEO penalizes those redirects which “destroy” the path structure. For example WWW → non-WWW redirect has to be with preserve_path_suffix.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.