Bug 63186 - Error pages aren't compressed (404, 410)
Summary: Error pages aren't compressed (404, 410)
Status: NEW
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: Core (show other bugs)
Version: 2.4.29
Hardware: PC Linux
: P2 major (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
Depends on:
Reported: 2019-02-17 22:40 UTC by ZK
Modified: 2019-02-24 07:33 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description ZK 2019-02-17 22:40:19 UTC

I've just noticed that the 404 et 410 pages of my websites aren't compressed (no Content-Encoding header, they're sent in plain text).
I use mod_brotli and mod_gzip as a fallback.

Maybe there's something wrong in my setup, but if that's the case, a lot of big websites have the same problem. Apparently, NGinx, Varnish and Caddy do compress 404 and 410 responses... but Apache httpd server doesn't.

This is a shame because some websites have a lot of these, not because they're broken, but because they have a lot of temporary content (events, classifieds, for exemple).
Plus, it makes the users wait longer to see a broken page, which is quite annoying.

Is there a good reason why Apache httpd doesn't compress 404 and 410 pages?
During my researches, I couldn't find anything about it, but found some quite big 404 pages, weighting more than 100KB, which is a lot on Edge connections.
Comment 1 Reindl Harald 2019-02-24 07:33:28 UTC
Apache Trafficserver as proxy suffers from the same problem

"content-encoding: br" for 200 responses, no content-encoding for 404 repsones and since the backend-httpd don't support "br" and backend connections don't send "Accept-Encoding" by intention to keep compression load from the backend it's for sure the proxy in my case