I'm trying to disable the X-Rewrite-URL header from my Craft CMS site. I have already tried disabling it via the secureHeaders setting in the general settings, but it still doesn't work.

Remove 'X-Rewrite-Url' from the secureHeaders configuration in my config/general.php file as follows:

'secureHeaders' => [

Despite these steps, the X-Rewrite-URL header is still being sent.

Has anyone else encountered this issue or have any suggestions on how to completely disable this header in Craft CMS? Any help would be greatly appreciated!

1 Answer 1


As far as I know Craft does not set that header automatically, so I'm guessing you are either looking at stale cache or your are behind a proxy like Cloudflare that is setting it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.