Start free · Free tools · Fair usage limits
Browse Tools

Categories

Custom AI Solutions – AI2Flows
LIVE NEWS
Loading latest AI & SEO news…
Home›Tools›HTTP Status Codes Reference›HTTP 421 Misdirected Request
4xx Client Error

HTTP 421 Misdirected Request

HTTP 421 Misdirected Request means the request reached a server that cannot produce a response for that hostname. It usually happens with HTTP/2 connection…

Quick answer

HTTP 421 Misdirected Request means the request reached a server that cannot produce a response for that hostname. It usually happens with HTTP/2 connection reuse, when a browser reuses a TLS connection for a different domain covered by the same certificate.

Last updated · Maintained by FreeAIToolz · How we test

What does HTTP 421 Misdirected Request mean?

HTTP/2 lets browsers reuse one connection for several hostnames that share an IP and certificate. If the server is not configured for one of those hosts, it returns 421 and the browser retries on a new connection.

Status code421
NameMisdirected Request
Class4xx Client Error
Defined inRFC 9110 §15.5.20
Cacheable by defaultNo, unless Cache-Control says so
Safe to retry automatically?No: change the request first

What causes HTTP 421?

  • HTTP/2 connection coalescing across domains on a wildcard or multi-domain certificate.
  • SNI and Host header mismatch behind a proxy.

How do I fix HTTP 421?

  1. Make sure every hostname on the certificate is served by the same server configuration, or use separate certificates.
  2. Check that the proxy forwards the correct Host and SNI.

What should a client do after HTTP 421?

Retry on a new connection (browsers do this automatically).

Does HTTP 421 affect SEO?

Rare. Persistent 421s on a domain can stop Googlebot fetching pages.

Example 421 response

HTTP/1.1 421 Misdirected Request
Date: Mon, 01 Dec 2026 12:00:00 GMT
Content-Type: application/json

{"error":{"status":421,"message":"Misdirected Request"}}

How to return 421 Misdirected Request in code

Express (Node.js)

res.status(421).json({ error: 'Misdirected Request' });

Next.js route handler

return Response.json({ error: 'Misdirected Request' }, { status: 421 });

FastAPI (Python)

raise HTTPException(status_code=421, detail="Misdirected Request")

PHP

http_response_code(421);

Nginx

location = /example {
    return 421;
}

Other 4xx status codes

The request contains an error or cannot be fulfilled as sent. Fix the request before retrying.

Frequently asked questions

Why do I see 421 only in some browsers?
Browsers differ in how aggressively they reuse HTTP/2 connections across hostnames. Fix the server so every certificate hostname is served correctly.
Is 421 a client or server problem?
Usually a server or proxy configuration issue, even though it is a 4xx code.
Is 421 a client or server error?
421 is in the 4xx class, so it is classed as a client error: the request needs to change before it can succeed. In practice 421 is usually caused by server or proxy configuration.