Is there any way to get curl to decompress a response without sending the Accept headers in the request?

Probably the easiest thing to do is just use gunzip to do it:

curl -sH 'Accept-encoding: gzip' http://example.com/ | gunzip -

Or there’s also --compressed, which curl will decompress (I believe) since it knows the response is compressed. But, not sure if that meets your needs.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)