--- title: 426 Upgrade Required slug: Web/HTTP/Status/426 tags: - 响应状态码 - 客户端错误 translation_of: Web/HTTP/Status/426 ---
{{HTTPSidebar}}

426 Upgrade Required 是一种HTTP协议的错误状态代码,表示服务器拒绝处理客户端使用当前协议发送的请求,但是可以接受其使用升级后的协议发送的请求。

服务器会在响应中使用 {{HTTPHeader("Upgrade")}} 首部来指定要求的协议。

状态

426 Upgrade Required

示例

HTTP/1.1 426 Upgrade Required
Upgrade: HTTP/3.0
Connection: Upgrade
Content-Length: 53
Content-Type: text/plain

This service requires use of the HTTP/3.0 protocol

规范

Specification Title
{{RFC("7231", "426 Upgrade Required" , "6.5.15")}} Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content

相关内容