The "Authorization" header is missing, what to do?
The Authorization header is not accessible by default with PHP-FPM (the solution we use to speed up PHP), but there is a simple way to retrieve it.
Simply add the following line to your .htaccess file:
SetEnvIf Authorization "(.*)" HTTP_AUTHORIZATION=$1Note: Several frameworks already include such a line (or an equivalent one) in their default configuration.
Similarly, if you expect to find the PHP_AUTH_USER or PHP_AUTH_PW variables, they are not present either, but you can recreate them by adding this code snippet at the beginning of your PHP files that need these variables:
list($_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW']) = explode(':', base64_decode(substr($_SERVER['HTTP_AUTHORIZATION'], 6)));
Updated on: 14/02/2026
Thank you!