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 1111753 of Accept-Ranges

  • Revision slug: Web/HTTP/Headers/Accept-Ranges
  • Revision title: Accept-Ranges
  • Revision id: 1111753
  • Created:
  • Creator: fscholz
  • Is current revision? Yes
  • Comment fix github url

Revision Content

{{HTTPSidebar}}

The Accept-Ranges response HTTP header is a marker used by the server to advertise its support of partial request. The value of this field indicates the unit that can be used to define the range.

In presence of an Accept-Ranges header, the browser may try to resume an interrupted download, rather than to start it from the start again.

Header type {{Glossary("Response header")}}
{{Glossary("Forbidden header name")}} no

Syntax

Accept-Ranges: bytes
Accept-Ranges: none

Directives

none
No range unit is supported, this makes the header equivalent of its own absence and is therefore rarely used
bytes

Ranges can be expressed in bytes.

Examples

Accept-Ranges: bytes

Specifications

Specification Title
{{RFC("7233", "Accept-Ranges", "2.3")}} Hypertext Transfer Protocol (HTTP/1.1): Range Requests

Browser compatibility

{{Compat}}

See also

  • {{HTTPHeader("If-Range")}}
  • {{HTTPHeader("Ranges")}}

Revision Source

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

<p>The <code><strong>Accept-Ranges</strong></code> response HTTP header is a marker used by the server to advertise its support of partial request. The value of this field indicates the unit that can be used to define the range.</p>

<p>In presence of an <code>Accept-Ranges</code> header, the browser may try to <em>resume</em> an interrupted download, rather than to start it from the start again.</p>

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

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

<pre class="syntaxbox">
Accept-Ranges: bytes
Accept-Ranges: none</pre>

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

<dl>
 <dt><code>none</code></dt>
 <dd>No range unit is supported, this makes the header equivalent of its own absence and is therefore rarely used</dd>
 <dt><code>bytes</code></dt>
 <dd>
 <p>Ranges can be expressed in bytes.</p>
 </dd>
</dl>

<h2 id="Examples">Examples</h2>

<pre>
Accept-Ranges: bytes
</pre>

<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("7233", "Accept-Ranges", "2.3")}}</td>
   <td>Hypertext Transfer Protocol (HTTP/1.1): Range Requests</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("If-Range")}}</li>
 <li>{{HTTPHeader("Ranges")}}</li>
</ul>
Revert to this revision