4xx Client ErrorHTTP Status Code Reference

HTTP 401 Unauthorized— What It Means, Causes & How to Fix It

The request requires user authentication. The client must provide valid credentials (such as a token or username/password) to access the resource. Despite the name, this is about authentication, not authorization.

Live URL Status Checker

Enter any URL to see its real HTTP response code

Common Causes

  • Missing or expired authentication token
  • Invalid API key or credentials
  • Session has timed out and user needs to re-login
  • Authorization header format is incorrect

How to Fix

  1. 1Include a valid Authorization header with your request
  2. 2Refresh expired tokens or re-authenticate
  3. 3Check that credentials are correct and not revoked
  4. 4Verify the authentication scheme (Bearer, Basic, etc.)

Example

HTTP 401 Unauthorized
GET /api/profile HTTP/1.1

→ 401 Unauthorized
→ WWW-Authenticate: Bearer realm="api"

Related Client Error Codes

Commonly Referenced Status Codes

The most frequently searched HTTP status codes

Related Tools