What encoding string tells a web server NOT to send gzip content?

saeed picture saeed · Sep 7, 2012 · Viewed 36.6k times · Source

This encoding header tells a web server to send gzip content if available.

'accept-encoding': 'gzip,deflate,sdch',

How can I instruct the web server to send plain text and not gzip the content? I am aware that the web server can simply ignore this request if it wanted to.

Answer

dude picture dude · Jul 30, 2014

Not including the accept-encoding header implies that you may want the default encoding, i.e. identity. The caveat here is that the RFC2616 sec 14.3 allows the server to assume any available encoding is acceptable.

To explicitly request plain text, set 'accept-encoding: identity'