Alt-Svc - HTTP - UDN Web Docs
- Syntax
- Example
- Specifications
- Browser compatibility
- See also
- Related topics
The Alt-Svc HTTP response header is used to advertise alternative services through which the same resource can be reached. An alternative service is defined by a protocol/host/port combination.
Syntax
Alt-Svc: clear Alt-Svc: <protocol-id>=<alt-authority>; ma=<max-age> Alt-Svc: <protocol-id>=<alt-authority>; ma=<max-age>; persist=1 clear The special value ''clear" indicates that the origin requests all alternatives for that origin to be invalidated. <protocol-id> The ALPN protocol identifier. Examples include h2 for HTTP/2 and h3-25 for draft 25 of the HTTP/3 protocol. <alt-authority> The quoted string specifying the alternative authority which consists of an optional host override, a colon, and a mandatory port number. ma=<max-age>Optional The number of seconds for which the alternative service is considered fresh. If omitted, it defaults to 24 hours. Alternative service entries can be cached for up to <max-age> seconds, minus the age of the response (from the Age header). If the cached entry expires, the client can no longer use this alternative service for new connections. persist=1Optional Usually cached alternative service entries are cleared on network configuration changes. Use of the persist=1 parameter ensures that the entry is not deleted through such changes.Multiple entries can be specified in a single Alt-Svc header using comma as separator. In that case, early entries are considered more preferable.
Example
Alt-Svc: h2=":443"; ma=2592000; Alt-Svc: h2=":443"; ma=2592000; persist=1 Alt-Svc: h2="alt.example.com:443", h2=":443" Alt-Svc: h3-25=":443"; ma=3600, h2=":443"; ma=3600Specifications
| Specification | Status | Comment |
|---|---|---|
| RFC 7838 | IETF RFC | Initial definition. |
Browser compatibility
The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.| Desktop | Mobile | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | Android webview | Chrome for Android | Firefox for Android | Opera for Android | Safari on iOS | Samsung Internet | |
| Alt-Svc | Chrome Full support Yes | Edge Full support ≤79 | Firefox Full support 38 Full support 38 No support 37 — 38Notes Notes Only supports draft-04 No support 35 — 37Notes Disabled Notes Only supports draft-03Disabled From version 35 until version 37 (exclusive): this feature is behind the network.http.altsvc.enabled preference (needs to be set to true) and the altsvc.oe preference (needs to be set to true). To change preferences in Firefox, visit about:config. | IE ? | Opera Full support Yes | Safari ? | WebView Android Full support Yes | Chrome Android Full support Yes | Firefox Android Full support 38 Full support 38 No support 37 — 38Notes Notes Only supports draft-04 No support 35 — 37Notes Disabled Notes Only supports draft-03Disabled From version 35 until version 37 (exclusive): this feature is behind the network.http.altsvc.enabled preference (needs to be set to true) and the altsvc.oe preference (needs to be set to true). To change preferences in Firefox, visit about:config. | Opera Android Full support Yes | Safari iOS ? | Samsung Internet Android Full support Yes |
Legend
Full support Full support Compatibility unknown Compatibility unknownSee implementation notes.See implementation notes.User must explicitly enable this feature.User must explicitly enable this feature.See also
- Identifying resources on the Web
- HTTP
- Guides:
- Resources and URIs
- Identifying resources on the Web
- Data URIs
- Introduction to MIME Types
- Complete list of MIME Types
- Choosing between www and non-www URLs
- HTTP guide
- Basics of HTTP
- Overview of HTTP
- Evolution of HTTP
- HTTP Messages
- A typical HTTP session
- Connection management in HTTP/1.x
- Protocol upgrade mechanism
- HTTP security
- Content Security Policy (CSP)
- HTTP Public Key Pinning (HPKP)
- HTTP Strict Transport Security (HSTS)
- Cookie security
- X-Content-Type-Options
- X-Frame-Options
- X-XSS-Protection
- Mozilla web security guidelines
- Mozilla Observatory
- HTTP access control (CORS)
- HTTP authentication
- HTTP caching
- HTTP compression
- HTTP conditional requests
- HTTP content negotiation
- HTTP cookies
- HTTP range requests
- HTTP redirects
- HTTP specifications
- Feature policy
- References:
- HTTP headers
- Accept
- Accept-CH
- Accept-CH-Lifetime
- Accept-Charset
- Accept-Encoding
- Accept-Language
- Accept-Patch
- Accept-Ranges
- Access-Control-Allow-Credentials
- Access-Control-Allow-Headers
- Access-Control-Allow-Methods
- Access-Control-Allow-Origin
- Access-Control-Expose-Headers
- Access-Control-Max-Age
- Access-Control-Request-Headers
- Access-Control-Request-Method
- Age
- Allow
- Alt-Svc
- Authorization
- Cache-Control
- Clear-Site-Data
- Connection
- Content-Disposition
- Content-Encoding
- Content-Language
- Content-Length
- Content-Location
- Content-Range
- Content-Security-Policy
- Content-Security-Policy-Report-Only
- Content-Type
- Cookie
- Cookie2
- Cross-Origin-Embedder-Policy
- Cross-Origin-Opener-Policy
- Cross-Origin-Resource-Policy
- DNT
- DPR
- Date
- Device-Memory
- Digest
- ETag
- Early-Data
- Expect
- Expect-CT
- Expires
- Feature-Policy
- Forwarded
- From
- Host
- If-Match
- If-Modified-Since
- If-None-Match
- If-Range
- If-Unmodified-Since
- Index
- Keep-Alive
- Large-Allocation
- Last-Modified
- Link
- Location
- NEL
- Origin
- Pragma
- Proxy-Authenticate
- Proxy-Authorization
- Public-Key-Pins
- Public-Key-Pins-Report-Only
- Range
- Referer
- Referrer-Policy
- Retry-After
- Save-Data
- Sec-Fetch-Dest
- Sec-Fetch-Mode
- Sec-Fetch-Site
- Sec-Fetch-User
- Sec-WebSocket-Accept
- Server
- Server-Timing
- Set-Cookie
- Set-Cookie2
- SourceMap
- Strict-Transport-Security
- TE
- Timing-Allow-Origin
- Tk
- Trailer
- Transfer-Encoding
- Upgrade-Insecure-Requests
- User-Agent
- Vary
- Via
- WWW-Authenticate
- Want-Digest
- Warning
- X-Content-Type-Options
- X-DNS-Prefetch-Control
- X-Forwarded-For
- X-Forwarded-Host
- X-Forwarded-Proto
- X-Frame-Options
- X-XSS-Protection
- HTTP request methods
- CONNECT
- DELETE
- GET
- HEAD
- OPTIONS
- PATCH
- POST
- PUT
- TRACE
- HTTP response status codes
- 100 Continue
- 101 Switching Protocols
- 103 Early Hints
- 200 OK
- 201 Created
- 202 Accepted
- 203 Non-Authoritative Information
- 204 No Content
- 205 Reset Content
- 206 Partial Content
- 300 Multiple Choices
- 301 Moved Permanently
- 302 Found
- 303 See Other
- 304 Not Modified
- 307 Temporary Redirect
- 308 Permanent Redirect
- 400 Bad Request
- 401 Unauthorized
- 402 Payment Required
- 403 Forbidden
- 404 Not Found
- 405 Method Not Allowed
- 406 Not Acceptable
- 407 Proxy Authentication Required
- 408 Request Timeout
- 409 Conflict
- 410 Gone
- 411 Length Required
- 412 Precondition Failed
- 413 Payload Too Large
- 414 URI Too Long
- 415 Unsupported Media Type
- 416 Range Not Satisfiable
- 417 Expectation Failed
- 418 I'm a teapot
- 422 Unprocessable Entity
- 425 Too Early
- 426 Upgrade Required
- 428 Precondition Required
- 429 Too Many Requests
- 431 Request Header Fields Too Large
- 451 Unavailable For Legal Reasons
- 500 Internal Server Error
- 501 Not Implemented
- 502 Bad Gateway
- 503 Service Unavailable
- 504 Gateway Timeout
- 505 HTTP Version Not Supported
- 506 Variant Also Negotiates
- 507 Insufficient Storage
- 508 Loop Detected
- 510 Not Extended
- 511 Network Authentication Required
- CSP directives
- CSP: base-uri
- CSP: block-all-mixed-content
- CSP: child-src
- CSP: connect-src
- CSP: default-src
- CSP: font-src
- CSP: form-action
- CSP: frame-ancestors
- CSP: frame-src
- CSP: img-src
- CSP: manifest-src
- CSP: media-src
- CSP: navigate-to
- CSP: object-src
- CSP: plugin-types
- CSP: prefetch-src
- CSP: referrer
- CSP: report-to
- CSP: report-uri
- CSP: require-sri-for
- CSP: sandbox
- CSP: script-src
- CSP: script-src-attr
- CSP: script-src-elem
- CSP: style-src
- CSP: style-src-attr
- CSP: style-src-elem
- CSP: trusted-types
- CSP: upgrade-insecure-requests
- CSP: worker-src
- CORS errors
- Reason: CORS disabled
- Reason: CORS header 'Access-Control-Allow-Origin' does not match 'xyz'
- Reason: CORS header 'Access-Control-Allow-Origin' missing
- Reason: CORS header ‘Origin’ cannot be added
- Reason: CORS preflight channel did not succeed
- Reason: CORS request did not succeed
- Reason: CORS request external redirect not allowed
- Reason: CORS request not HTTP
- Reason: Credential is not supported if the CORS header ‘Access-Control-Allow-Origin’ is ‘*’
- Reason: Did not find method in CORS header ‘Access-Control-Allow-Methods’
- Reason: Multiple CORS header 'Access-Control-Allow-Origin' not allowed
- Reason: expected ‘true’ in CORS header ‘Access-Control-Allow-Credentials’
- Reason: invalid token ‘xyz’ in CORS header ‘Access-Control-Allow-Headers’
- Reason: invalid token ‘xyz’ in CORS header ‘Access-Control-Allow-Methods’
- Reason: missing token ‘xyz’ in CORS header ‘Access-Control-Allow-Headers’ from CORS preflight channel
- Feature-Policy directives
- Feature-Policy: accelerometer
- Feature-Policy: ambient-light-sensor
- Feature-Policy: autoplay
- Feature-Policy: battery
- Feature-Policy: camera
- Feature-Policy: display-capture
- Feature-Policy: document-domain
- Feature-Policy: encrypted-media
- Feature-Policy: fullscreen
- Feature-Policy: geolocation
- Feature-Policy: gyroscope
- Feature-Policy: layout-animations
- Feature-Policy: legacy-image-formats
- Feature-Policy: magnetometer
- Feature-Policy: microphone
- Feature-Policy: midi
- Feature-Policy: oversized-images
- Feature-Policy: payment
- Feature-Policy: picture-in-picture
- Feature-Policy: publickey-credentials-get
- Feature-Policy: screen-wake-lock
- Feature-Policy: sync-xhr
- Feature-Policy: unoptimized-images
- Feature-Policy: unsized-media
- Feature-Policy: usb
- Feature-Policy: vibrate
- Feature-Policy: wake-lock
- Feature-Policy: xr
- Feature-Policy: xr-spatial-tracking
Từ khóa » Http 3 Alt-svc
-
Alt-Svc - HTTP - MDN Web Docs
-
Bootstrap With Alt-svc - README - HTTP/3 Explained
-
RFC 7838 - HTTP Alternative Services - IETF Tools
-
Configuring HTTP/3 Discovery For BIG-IP Virtual Server - AskF5
-
Alt-Svc - HTTP - W3cubDocs
-
Alt-Svc | Fastly Developer Hub
-
How Does A Browser Know If A Site Supports HTTP/3? - Stack Overflow
-
The Alt-Svc HTTP Header Allows A Server To Indicate That A Particular ...
-
HTTP/3 Service Discovery | Citrix ADC 13.1
-
IIS'de HTTP/3 Ile ASP.NET Core Kullanma | Microsoft Docs
-
RFC 9114: HTTP/3
-
HTTP/3 Support
-
Alternative Services - Everything Curl
-
HTTP Headers | Alt-Svc - GeeksforGeeks