overleaf-mcp
Provides an MCP bridge for Overleaf, enabling interaction with projects on an Overleaf instance via its web API using the configured account's permissions. Targets self-hosted Overleaf Community Edition.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@overleaf-mcpshow me the files in my thesis project"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Overleaf MCP Bridge
MCP bridge for Overleaf that uses its web API directly. Targets self-hosted Overleaf Community Edition and CEP-only features. Not guaranteed to work with the official Overleaf SaaS or Server Pro, as the author has no paid account to verify against.
Install
From Source Code
This project is a Python package, requiring Python 3.12 or newer. Install it with uv:
git clone https://github.com/Firefox2100/overleaf-mcp.git
cd overleaf-mcp
uv syncFrom a Container Image
A prebuilt image is published to GitHub Container Registry on every push to main:
docker pull ghcr.io/firefox2100/overleaf-mcp:latestOr with Compose, using the provided compose.yaml (defaults to streamable HTTP on port 8000):
cp example.env .env
docker compose up -dSet the environment variables in the .env file before starting. See Configuration below.
Related MCP server: openevidence-mcp
Configuration
Settings are read from the enviornment, in this order of precedence:
environment variables in the shell
an
.envfile (or the file named byOMCP_ENV_FILE)Docker secrets under
/run/secrets
Setting | Env var | Docker secret file | Required | Default |
Overleaf account email |
|
| yes | — |
Overleaf account password |
|
| yes | — |
Overleaf base URL |
|
| no |
|
Example .env:
OMCP_OVERLEAF_BASE_URL=https://overleaf.example.com
OMCP_OVERLEAF_EMAIL=service@example.com
OMCP_OVERLEAF_PASSWORD=...The account used should have its own credentials and only the access it needs — this bridge logs in as that account and acts with its permissions. Giving it a personal account with full access to all projects, or admin access, is not recommended as the MCP client would be able to perform much more destructive actions than perhaps intended.
Running
stdio
uv run overleaf-mcpEquivalently, as a module: uv run python -m overleaf_mcp.
By default, this speaks MCP over stdio, so it's meant to be launched by an MCP client (not run standalone). On startup, it logs in to Overleaf immediately and fails fast if that doesn't work — nothing is served on a broken session. After a successful login, the environment variables for email and password are not needed, and can be removed for the next run. The bridge will keep using the same session when possible.
To wire it into an MCP client, point the client at the overleaf-mcp command with the environment variables set, e.g. for a client that reads a JSON config with a mcpServers map:
{
"mcpServers": {
"overleaf": {
"command": "overleaf-mcp",
"env": {
"OMCP_OVERLEAF_BASE_URL": "https://overleaf.example.com",
"OMCP_OVERLEAF_EMAIL": "service@example.com",
"OMCP_OVERLEAF_PASSWORD": "..."
}
}
}
}If overleaf-mcp isn't on the client's PATH, point command at uv --directory /path/to/overleaf-mcp run overleaf-mcp instead.
Streamable HTTP
Pass --http to serve over streamable HTTP instead of stdio — useful when running the bridge as a standalone service (e.g. in a container) or with other proxy clients like LiteLLM rather than spawning it per-client:
uv run overleaf-mcp --http --host 0.0.0.0 --port 8000--host and --port are ignored for the default stdio transport. Point an HTTP-capable MCP client at http://<host>:<port>/mcp.
Tools
Tools are grouped into namespaces, each mounted as its own set of <namespace>_<tool> MCP tools. A namespace with CEP-specific tools is only mounted when the connected server is probed at startup and found to actually support that feature — a plain Overleaf CE server never exposes it, so clients don't need to know or care which kind of server they're talking to.
Namespace | Always mounted | Purpose |
| yes | List, fetch, create, delete, and clone projects; download a project as a zip; list collaborators. |
| yes | Read, list, create, rename, move, overwrite, patch, and delete files; create/refresh linked files (e.g. imported from a URL, or Zotero-linked |
| yes | Trigger a compile (draft or full), fetch compile logs/errors, download an output file, and get a word count. |
| yes | Search across a project or within a file (plain or regex), outline a file's structure, and read a specific line range. |
| yes | Read/update project config: compiler, root document, main bibliography, spell-check language, and (on CEP) the sandboxed-compile TeX Live image. |
| yes | List |
| yes | List project history, diff a file between versions, restore a file to a prior version, and manage history labels. |
| only if the server supports review mode (CEP) | Track changes (enable/disable, tracked edits, accept/reject) and comment threads (create, reply, resolve, reopen, delete). |
| only if | Read GitHub sync state and trigger a sync. Linking/unlinking a repository stays a web-UI action, out of scope here. |
| only if | Export a whole project to |
Every tool operates on an already-authenticated session established at startup — there is no per-call login, and no tool exposes credentials or session details to the client.
Each tool's docstring documents its own parameters and behavior in detail. For the concepts that span multiple tools — the project_id/path conventions, read-before-write safety, and typical multi-step workflows (editing, compiling, citations, review, history) — see skill/SKILL.md. It's written as a portable Claude skill: drop the skill folder into an MCP client's skills directory (e.g. .claude/skills/overleaf-mcp for Claude Code) to give it that context automatically.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
No tool schema history has been recorded yet.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Browser MCP for logged-in tasks. Uses your Chrome — credentials stay local. Zero-token replay.
An authenticated remote MCP server for user-owned devices and one-shot capability invocation.
Connect AI agents to Filepad workspaces through OAuth MCP.
Governed MCP gateway: one endpoint for your tools, with credential custody and audit log.
Related MCP Servers
FlicenseNot gradedqualityDmaintenanceEnables external MCP clients to execute Mittwald CLI commands on behalf of users via stateless OAuth authentication.3-- AlicenseAqualityBmaintenanceConnects OpenEvidence to MCP clients for authenticated research queries using your browser session.54940Apache 2.0
- AlicenseNot gradedqualityCmaintenanceEnables MCP clients to authenticate with Google OAuth and securely access Google Calendar's official MCP server without exposing the Google client secret.MIT
- AlicenseNot gradedqualityBmaintenanceEnables clients to access multiple backend MCP servers through a single endpoint, with OAuth 2.1 authorization, namespaced tools, and secure credential management.MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Firefox2100/overleaf-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server