Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

Revision 1111815 of TE

  • Revision slug: Web/HTTP/Headers/TE
  • Revision title: TE
  • Revision id: 1111815
  • Created:
  • Creator: fscholz
  • Is current revision? Yes
  • Comment fix github url

Revision Content

{{HTTPSidebar}}

The TE request header specifies the transfer encodings the user agent is willing to accept. (you could informally call it Accept-Transfer-Encoding, which would be more intuitive).

See also the {{HTTPHeader("Transfer-Encoding")}} response header for more details on transfer encodings. Note that chunked is always acceptable for HTTP/1.1 recipients and you that don't have to specify "chunked" using the TE header. However, it is useful for setting if the client is accepting trailer fields in a chunked transfer coding using the "trailers" value.

Header type {{Glossary("Request header")}}
{{Glossary("Forbidden header name")}} yes

Syntax

TE: compress
TE: deflate
TE: gzip
TE: trailers

// Multiple directives, weighted with the {{glossary("quality values", "quality value")}} syntax:
TE: trailers, deflate;q=0.5

Directives

compress
A format using the Lempel-Ziv-Welch (LZW) algorithm is accepted as a transfer coding name.
deflate
Using the zlib structure is accepted as a transfer coding name.
gzip
A format using the Lempel-Ziv coding (LZ77), with a 32-bit CRC is accepted as a transfer coding name.
trailers
Indicates that the client is willing to accept trailer fields in a chunked transfer coding.
q

When multiple transfer codings are acceptable, the q parameter of the quality value syntax can rank codings by preference.

Specifications

Specification Title
{{RFC("7230", "TE", "4.3")}} Hypertext Transfer Protocol (HTTP/1.1): Message Syntax and Routing

Browser compatibility

{{Compat}}

See also

Revision Source

<div>{{HTTPSidebar}}</div>

<p>The <code><strong>TE</strong></code> request header specifies the transfer encodings the user agent is willing to accept. (you could informally call it <em><code>Accept-Transfer-Encoding</code></em>, which would be more intuitive).</p>

<p>See also the {{HTTPHeader("Transfer-Encoding")}} response header for more details on transfer encodings. Note that <code>chunked</code> is always acceptable for HTTP/1.1 recipients and you that don't have to specify <code>"chunked"</code> using the <code>TE</code> header. However, it is useful for setting if the client is accepting trailer fields in a chunked transfer coding using the "trailers" value.</p>

<table class="properties">
 <tbody>
  <tr>
   <th scope="row">Header type</th>
   <td>{{Glossary("Request header")}}</td>
  </tr>
  <tr>
   <th scope="row">{{Glossary("Forbidden header name")}}</th>
   <td>yes</td>
  </tr>
 </tbody>
</table>

<h2 id="Syntax">Syntax</h2>

<pre class="syntaxbox">
TE: compress
TE: deflate
TE: gzip
TE: trailers

// Multiple directives, weighted with the {{glossary("quality values", "quality value")}} syntax:
TE: trailers, deflate;q=0.5
</pre>

<h2 id="Directives">Directives</h2>

<dl>
 <dt><code>compress</code></dt>
 <dd>A format using the <a class="external" href="https://en.wikipedia.org/wiki/LZW">Lempel-Ziv-Welch</a> (LZW) algorithm is accepted as a transfer coding name.</dd>
 <dt><code>deflate</code></dt>
 <dd>Using the <a class="external" href="https://en.wikipedia.org/wiki/Zlib">zlib</a> structure is accepted as a transfer coding name.</dd>
 <dt><code>gzip</code></dt>
 <dd>A format using the <a class="external" href="https://en.wikipedia.org/wiki/LZ77_and_LZ78#LZ77">Lempel-Ziv coding</a> (LZ77), with a 32-bit CRC is accepted as a transfer coding name.</dd>
 <dt>trailers</dt>
 <dd>Indicates that the client is willing to accept trailer fields in a chunked transfer coding.</dd>
 <dt>q</dt>
 <dd>
 <p>When multiple transfer codings are acceptable, the <code>q</code> parameter of the <a href="/en-US/docs/Glossary/Quality_values">quality value</a> syntax can rank codings by preference.</p>
 </dd>
</dl>

<h2 id="Specifications">Specifications</h2>

<table class="standard-table">
 <tbody>
  <tr>
   <th scope="col">Specification</th>
   <th scope="col">Title</th>
  </tr>
  <tr>
   <td>{{RFC("7230", "TE", "4.3")}}</td>
   <td>Hypertext Transfer Protocol (HTTP/1.1): Message Syntax and Routing</td>
  </tr>
 </tbody>
</table>

<h2 id="Browser_compatibility">Browser compatibility</h2>

<p class="hidden">The compatibility table in this page is generated from structured data. If you'd like to contribute to the data, please check out <a href="https://github.com/mdn/browser-compat-data">https://github.com/mdn/browser-compat-data</a> and send us a pull request.</p>

<p>{{Compat}}</p>

<h2 id="See_also">See also</h2>

<ul>
 <li>{{HTTPHeader("Transfer-Encoding")}}</li>
 <li>{{HTTPHeader("Trailer")}}</li>
 <li>
  <p><a href="https://en.wikipedia.org/wiki/Chunked_transfer_encoding">Chunked transfer encoding</a></p>
 </li>
</ul>
Revert to this revision