How to check with curl if my website or the asset is gzipped ?
Problem :
You are trying to improve your PageSpeed score and trying to gzip the output of your website. You need to check from command line to see if your website output is gzipped.
Solution :
Use curl --compressed --head <your website URL or assets URL>
command. If the content is gzipped, you should see this line in the reply.
Content-Encoding: gzip
By Adam Ng
IF you gain some knowledge or the information here solved your programming problem. Please consider donating to the less fortunate or some charities that you like. Apart from donation, planting trees, volunteering or reducing your carbon footprint will be great too.
Advertisement
Tutorials
+27.8k Golang : Save map/struct to JSON or XML file
+9.3k Golang : Generate 403 Forbidden to protect a page or prevent indexing by search engine
+8.1k Golang : Timeout example
+6k Linux : How to fix Brother HL-1110 printing blank page problem
+25.1k Golang : Calculate future date with time.Add() function
+15.7k Golang : How to tell if a file is compressed either gzip or zip ?
+32.8k Golang : How to stream file to client(browser) or write to http.ResponseWriter?
+3.9k Javascript : How to get width and height of a div?
+10.7k Golang : md5 hash of a string
+23.5k Golang : convert rune to integer value
+7.9k Golang : How to extract video or image files from html source code
+37.8k Golang : How to iterate over a []string(array)