MCP connectors (claude.ai / Claude Desktop) never fall back to anonymous access when a server advertises optional OAuth
Summary
When a remote MCP server advertises an OAuth authorization server (RFC 9728 protected-resource metadata / RFC 8414 discovery), the claude.ai and Claude Desktop connector flows demand a login at setup — even when the server also allows anonymous access and would happily serve a public tool surface without credentials.
Per the MCP spec, authorization is optional: clients are expected to attempt requests and react to a 401 challenge if the server requires auth. A server that returns 200 to unauthenticated requests is advertising OAuth as an upgrade path, not a requirement. Claude Code's HTTP MCP transport handles this correctly (connects anonymously, authenticates on 401); the claude.ai and Desktop connector UIs front-load the OAuth decision instead.
Why this matters
We run a CMS (Total CMS) whose built-in MCP server serves three tiers from one endpoint: anonymous → public collections/tools, OAuth → more, API key → admin. The anonymous tier exists precisely so site visitors can point their AI client at a site and browse its public content.
For visitors using claude.ai or Claude Desktop, that tier is unreachable: the app sees discoverable OAuth and walls the connector behind a login — and the server's OAuth consent screen requires an operator account that a visitor doesn't have and can never get. The result is a dead end for exactly the audience public MCP access is designed for.
Server operators are left with an ugly workaround: disable the OAuth server entirely (404 the well-knowns) so the Claude apps treat the endpoint as a no-auth server — losing the authenticated tier for everyone, on every client.
Expected behavior
One of:
- Try-first: attempt the connection anonymously; only initiate OAuth when the server answers 401 (matches the spec and Claude Code's behavior), offering "connect account" as an optional upgrade; or
- At minimum, a "connect without an account" option when the server demonstrably serves unauthenticated requests.
Reproduction
- MCP server that allows anonymous access AND advertises OAuth:
https://totalcms.co/mcp(discovery:https://totalcms.co/.well-known/mcp.json, noteauth.public: truealongsideresourceMetadata). curl -X POST https://totalcms.co/mcpwith aninitializepayload and no credentials → 200, full public handshake;tools/listreturns 13 tools.- Add the same URL as a claude.ai or Claude Desktop connector → login required; no anonymous option. The consent screen it leads to is operator-only, so a non-operator can never complete setup.
Filed from a Claude Code session, at the request of the site's operator.