Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do you know if the HTTP compression is working?

Tags:

How do you know if the HTTP compression setup is working? Is there any tool I can use to see the compressed page before it is uncompressed by the browser? Are there any tools to measure the amount compressed and response speed?

like image 533
Hanz Avatar asked Oct 02 '08 02:10

Hanz


People also ask

How do I know my HTTP compression is working?

Simply right click on a request, then click Header Options , Response Headers , and then select Content-Encoding . Show activity on this post.

What is HTTP response compression?

HTTP compression allows content to be compressed on the server before transmission to the client. For resources such as text this can significantly reduce the size of the response message, leading to reduced bandwidth requirements and download times.

How do I know if gzip is working?

Double click on the file and select headers. Under 'Response headers' you are looking for the 'Connection-Encoding' field, it will say gzip if it is enabled.


2 Answers

This isn't IIS-specific, but you can use cURL:

curl -H 'Accept-Encoding: gzip,deflate' -D - http://example.com 

Then look for a Content-Encoding: gzip header in the output.

like image 149
bcattle Avatar answered Oct 11 '22 10:10

bcattle


For Windows, I highly recommend Fiddler, which is a client-side tool that proxies your web traffic and lets you examine it. It will show you if compression is on and working. It is also useful for many other client-side HTTP-related debugging and diagnosis tasks.

like image 25
Tim Farley Avatar answered Oct 11 '22 11:10

Tim Farley