Overleaf MCP
Model Context Protocol (MCP) server that lets AI assistants read Overleaf projects, parse LaTeX document structure, and push section-level edits back via Git. Compatible with Claude Desktop, Cursor, Windsurf, and any MCP client.
What is Overleaf MCP?
Overleaf MCP is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to model context protocol (mcp) server that lets ai assistants read overleaf projects, parse latex document structure, and push section-level edits back via git. compatible with claude desktop, cursor, w...
Model Context Protocol (MCP) server that lets AI assistants read Overleaf projects, parse LaTeX document structure, and push section-level edits back via Git. Compatible with Claude Desktop, Cursor, Windsurf, and any MCP client.
This server falls under the Cloud Services category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Model Context Protocol (MCP) server that lets AI assistants
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx overleafmcpConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Overleaf MCP
OverleafMCP is a Model Context Protocol server that bridges AI assistants and Overleaf's collaborative LaTeX editor through Overleaf's Git integration. It lets AI clients read project files, parse LaTeX document structure into sections, and push section-level or full-file edits back to Overleaf via Git commits — all without leaving your AI chat interface. Writers, academics, and researchers who maintain LaTeX papers on Overleaf can use it to have AI assistants draft sections, rewrite content, or restructure documents directly in their Overleaf projects.
Prerequisites
- An Overleaf account with Git integration enabled (requires Overleaf Premium or institutional access)
- An Overleaf Git token — generate from Account Settings → Git Integration in Overleaf
- Your Overleaf project ID — visible in the project URL (e.g., overleaf.com/project/<PROJECT_ID>)
- Node.js 18+ installed
- An MCP-compatible client such as Claude Desktop, Cursor, or Windsurf
Get your Overleaf Git token and project ID
In Overleaf, go to Account Settings → Git Integration and generate a Git token. Then open your project and copy the project ID from the URL bar (the alphanumeric string after /project/).
Add the OverleafMCP server to your MCP client config
Add the @mjyoo2/overleaf-mcp package to your MCP client configuration using npx. Set OVERLEAF_PROJECT_ID and OVERLEAF_GIT_TOKEN as environment variables.
{
"mcpServers": {
"overleaf": {
"command": "npx",
"args": ["-y", "@mjyoo2/overleaf-mcp"],
"env": {
"OVERLEAF_PROJECT_ID": "your_project_id_here",
"OVERLEAF_GIT_TOKEN": "your_git_token_here"
}
}
}
}Configure multiple projects (optional)
To work with multiple Overleaf projects, create a projects.json config file and point to it with OVERLEAF_PROJECTS_CONFIG. The file should list each project with its ID, token, and display name.
{
"mcpServers": {
"overleaf": {
"command": "npx",
"args": ["-y", "@mjyoo2/overleaf-mcp"],
"env": {
"OVERLEAF_PROJECTS_CONFIG": "/absolute/path/to/projects.json"
}
}
}
}Restart your MCP client
Restart Claude Desktop (or your MCP client) to load the new server configuration.
Test the connection by listing your project files
Ask your AI assistant to list the files in your Overleaf project to confirm the server is connected and authenticated correctly.
Overleaf MCP Examples
Client configuration
Claude Desktop configuration for OverleafMCP with a single Overleaf project using an inline Git token.
{
"mcpServers": {
"overleaf": {
"command": "npx",
"args": ["-y", "@mjyoo2/overleaf-mcp"],
"env": {
"OVERLEAF_PROJECT_ID": "64a1b2c3d4e5f6a7b8c9d0e1",
"OVERLEAF_GIT_TOKEN": "your_overleaf_git_token",
"OVERLEAF_PROJECT_NAME": "My Research Paper"
}
}
}
}Prompts to try
Example prompts for reading and editing LaTeX documents in Overleaf through the MCP server.
- "List all files in my Overleaf project"
- "Read the contents of main.tex"
- "Show me the section structure of main.tex"
- "Get the content of the Introduction section from main.tex"
- "Rewrite the Abstract section to be more concise and add a sentence about our methodology"
- "Update the Conclusion section with the following text: [your text here] and commit with message 'Update conclusion'"Troubleshooting Overleaf MCP
Authentication fails — Git push to Overleaf is rejected
Regenerate your Git token from Overleaf Account Settings → Git Integration. Ensure the OVERLEAF_GIT_TOKEN value in your config exactly matches the token shown (no extra spaces). Some accounts require enabling Git integration in Overleaf settings first.
Project ID not recognized — 'repository not found' error
Copy the project ID directly from the Overleaf project URL (the string after /project/). Ensure it is the project ID and not the project name. The ID is typically a 24-character hexadecimal string.
Windows users: npx command fails or path errors
On Windows, change the command to 'cmd' and use args: ["/c", "npx", "-y", "@mjyoo2/overleaf-mcp"] in your MCP config. This properly invokes npx through the Windows command processor.
Frequently Asked Questions about Overleaf MCP
What is Overleaf MCP?
Overleaf MCP is a Model Context Protocol (MCP) server that model context protocol (mcp) server that lets ai assistants read overleaf projects, parse latex document structure, and push section-level edits back via git. compatible with claude desktop, cursor, windsurf, and any mcp client. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Overleaf MCP?
Follow the installation instructions on the Overleaf MCP GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Overleaf MCP?
Overleaf MCP works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Overleaf MCP free to use?
Yes, Overleaf MCP is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
Overleaf MCP Alternatives — Similar Cloud Services Servers
Looking for alternatives to Overleaf MCP? Here are other popular cloud services servers you can use with Claude, Cursor, and VS Code.
Open WebUI
★ 138.2kUser-friendly AI Interface (Supports Ollama, OpenAI API, ...)
Anything LLM
★ 60.4kThe all-in-one AI productivity accelerator. On device and privacy first with no annoying setup or configuration.
LocalAI
★ 46.4kLocalAI is the open-source AI engine. Run any model - LLMs, vision, voice, image, video - on any hardware. No GPU required.
Nacos
★ 33.0kan easy-to-use dynamic service discovery, configuration and service management platform for building AI cloud native applications.
Xiaozhi ESP32
★ 26.7k本项目为xiaozhi-esp32提供后端服务,帮助您快速搭建ESP32设备控制服务器。Backend service for xiaozhi-esp32, helps you quickly build an ESP32 device control server.
Gateway
★ 11.8kA blazing fast AI Gateway with integrated guardrails. Route to 1,600+ LLMs, 50+ AI Guardrails with 1 fast & friendly API.
Browse More Cloud Services MCP Servers
Explore all cloud services servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Overleaf MCP in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Overleaf MCP?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.