Error Code Portal
CloudflareCloudflare HTTP errorsError code

1040

Error 1040: Invalid request rewrite (header modification not allowed)

Alternative forms: Error 1040

Code 1040 · An issue reported by Cloudflare HTTP errors.

This error indicates that an attempt was made to modify a restricted HTTP header. You are trying to modify an HTTP header that Request Header Transform Rules cannot change.

Troubleshooting and diagnostic links

First check that the document's product, version, and environment match your situation.