One login page for any MCP server¶
mcp-login-proxy puts an OAuth login in front of an MCP server, so claude.ai, the Claude apps, Claude Code and any other MCP client can connect by URL and sign in once on a form. Requests then pass through to the server unchanged. Everything about the server behind it is one config file.
What it is for¶
Many MCP servers either take a credential on every request (an API token, Basic user:token, a session token from a login call) or have no login at all. MCP clients like claude.ai can't send such headers; they expect OAuth. The proxy is that OAuth login:
- A form, checked the way the server needs. The config file chooses one of three checks:
users: a fixed list of users and argon2id password hashes, for a server with no login of its own.upstream: the form's values are tried with one request to the server, for one that takes a credential per request.exchange: the form is sent to a login URL and a field of the answer becomes the token, for one that hands out tokens on login (Trilium Notes, for example).
- The server's own tools, unchanged. Every
/mcprequest goes to the server as it is. The proxy only adds the headers the config file names, rendered from that login. New tools from a server update appear without a proxy release. - Credentials stay on your side. The login page is the proxy's own; the MCP client only ever holds opaque OAuth tokens that mean nothing elsewhere. See Security.
- House rules. With
instructionsset, every client gets your standing instructions when it connects.
Examples¶
Ready-made config files are in docs/examples: Trilium Notes' built-in MCP server, OpenCloud's MCP server, and OpenBB's MCP server.
History¶
The proxy started as trilium-mcp-proxy, an OAuth front for Trilium Notes only, and became general in v0.2.0 (ADR 0003). A Trilium deployment of trilium-mcp-proxy moves over with the Trilium example config, and its existing logins keep working.