Lab-tested: Python 3.13.5 + Node 22.23.3 parsers (lab) · 2 Dec 2026 · Eight real challenges decoded and verified
Get the value with curl -si on an endpoint you own. The challenge is printed on every 401 response. Never paste tokens here; this tool only needs the challenge, which contains no secrets.
Fix Box — Try This First (10 Seconds)
Paste the WWW-Authenticate value from your 401 response into the inspector below. It splits the scheme, realm, error code, and description, then explains each part in plain language with the fix it points to.
The challenge contains no secrets, and everything runs in your browser. No challenge in your response? That itself is a finding — see the pillar 401 Unauthorized: Causes and How to Fix It.
Inspect Your Challenge Now
Capture the header first: curl -si https://your-endpoint.example/protected and copy the WWW-Authenticate: line's value. Paste it above and run the inspector.
You get the parsed parameters plus a plain-language reading of each one. For a quick start, load the lab example — a real insufficient_scope capture from our OAuth lab.
Anatomy of a Challenge
Per RFC 9110 Section 11.6.1, a challenge is a scheme name followed by parameters. The scheme (Bearer, Basic, Digest) names the credential format the server expects.
Parameters are key="value" pairs separated by commas: realm, error, error_description, scope, charset, and scheme-specific ones like nonce for Digest.
One exception matters for parsers: some schemes send a single token68 blob instead of parameters (the classic case is Negotiate). A naive comma-splitter mangles quoted values that contain commas, which is why this inspector parses quoted strings properly instead of splitting blindly.
What Each Parameter Means
realm is the protection space name, and practically it tells you which layer is asking: your app, nginx auth_basic, an Apache-protected folder, or an OAuth token endpoint. error is the machine-readable verdict for Bearer: invalid_request (malformed request), invalid_token (expired, revoked, or invalid), insufficient_scope (valid token, missing scope).
error_description is the human wording; search for it verbatim when stuck.
scope names the scope the resource requires, present on insufficient_scope challenges. charset="UTF-8" on Basic challenges tells you to encode credentials as UTF-8 before base64.
And the absence of error is itself diagnostic: with Bearer it usually means no credentials were presented at all, which points at your client or a header-stripping proxy — the Decision Tree walks that branch.
Eight Challenges From Our Lab
We decoded eight real challenges captured in our labs on 2 Dec 2026: a bare Bearer challenge, expired-token and insufficient-scope Bearer challenges from our mock OAuth server, Basic challenges from nginx auth_basic and the OAuth token endpoint, a Digest challenge, a bare Negotiate, and an invalid_request format error. Two independent parser implementations (Python 3.13.5 and the JavaScript in this tool, tested under Node 22.23.3) agreed on all eight: scheme and every parameter extracted correctly, 24 checks passed, 0 failed.
Full output is stored with this package as lab evidence.
The insufficient-scope capture is the best illustration of why parsing beats eyeballing:
WWW-Authenticate: Bearer realm="api", scope="write", error="insufficient_scope", error_description="Token scope does not include write"
Five facts in one line: scheme Bearer, realm api, required scope write, verdict insufficient_scope, and the server's own explanation. The fix (re-authorize with the write scope) is fully determined by this header.
Our OAuth guide covers that flow end to end.
What Did Not Work
Splitting the challenge on commas failed immediately in our lab: error_description values can contain commas inside quotes, and the naive split shredded them. The parser now walks quoted strings character by character.
If you write your own parser, test it against a description with a comma before trusting it.
Assuming every challenge has parameters also failed: Negotiate arrives bare or with a token68 blob. The parser handles that shape explicitly instead of reporting a broken challenge. A decoder that cries wolf on valid input teaches users to ignore it.
FAQ
Is it safe to paste my header here? Yes. WWW-Authenticate is a server response header; it contains no tokens or passwords.
The tool runs in your browser and sends nothing anywhere. Never paste your Authorization request header into any web tool, including this one — it is not needed here.
Where do I get the header value? Run curl -si on your endpoint and copy the WWW-Authenticate: line. Browsers hide this header from cross-origin JavaScript, so curl is the reliable capture method.
My 401 has no WWW-Authenticate header. What does that mean? The response likely came from a WAF, CDN, or custom layer rather than the app, or the server is non-standard. Start from the pillar guide's layer diagnosis.
What is the difference between this tool and the 401 Checker? The 401 Checker makes a request and reports status plus challenge.
The Header Inspector decodes a challenge you already captured. Use the checker to capture, the inspector to understand.
Why does the same API return different challenges? Because the failure differs: missing header, expired token, wrong scope, and malformed format each produce a different challenge. That variation is the diagnostic value.
Sources and Date
Lab tests run 2 Dec 2026: Python 3.13.5 reference parser and Node 22.23.3 tool-logic harness, against challenges captured the same day from our mock OAuth server (Python 3.13.5) and nginx 1.26.3 lab. Standards references verified live on 2 Dec 2026.
References
- RFC 9110, HTTP Semantics, Section 11.6.1 (WWW-Authenticate) and Section 15.5.2 (401 Unauthorized): https://www.rfc-editor.org/rfc/rfc9110.html
- RFC 6750, OAuth 2.0 Bearer Token Usage, Section 3 (WWW-Authenticate) and 3.1 (error codes): https://www.rfc-editor.org/rfc/rfc6750.html
- MDN Web Docs, WWW-Authenticate: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/WWW-Authenticate
- MDN Web Docs, 401 Unauthorized: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/401

