Overleaf
MCP server for Overleaf projects. Syncs LaTeX files via Git, parses sections, equations, and citations, and exposes them to AI clients for assisted paper review, LaTeX fixes, and content generation.
What is Overleaf?
Overleaf is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to mcp server for overleaf projects. syncs latex files via git, parses sections, equations, and citations, and exposes them to ai clients for assisted paper review, latex fixes, and content generation.
MCP server for Overleaf projects. Syncs LaTeX files via Git, parses sections, equations, and citations, and exposes them to AI clients for assisted paper review, LaTeX fixes, and content generation.
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- MCP server for Overleaf projects. Syncs LaTeX files via Git,
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx overleafConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Overleaf
The Overleaf MCP Server bridges AI assistants with your Overleaf LaTeX projects by syncing files via Overleaf's Git integration, then parsing and exposing sections, equations, and citations as MCP resources. This lets you ask an AI assistant to review your paper, fix LaTeX errors, rewrite sections, or generate new content while the changes are automatically committed and pushed back to Overleaf. It is designed for researchers and academics who want AI-assisted writing without leaving their existing Overleaf workflow.
Prerequisites
- Python 3.13 or later and the uv package manager installed
- An Overleaf account on an Individual, Group, or Institution plan that includes Git integration
- An Overleaf Git integration token generated from Account Settings → Git integration authentication tokens
- Your Overleaf project ID, visible in the project URL (e.g., overleaf.com/project/<PROJECT_ID>)
- An MCP-compatible client such as Claude Desktop
Generate an Overleaf Git token
Log in to Overleaf, go to Account Settings, scroll to the 'Git integration authentication tokens' section, and click 'Generate new token'. Copy the token immediately as it will not be shown again.
Clone the MCP server repository and install dependencies
Clone the repository and use uv to sync the Python virtual environment.
git clone https://github.com/YounesBensafia/overleaf-mcp-server.git
cd overleaf-mcp-server
uv syncConfigure environment variables
Copy the example env file and populate it with your Overleaf credentials.
cp .env.example .env
# Edit .env and set:
# OVERLEAF_TOKEN=<your-git-integration-token>
# PROJECT_ID=<your-overleaf-project-id>Start the MCP server
Run the server with uv. It will connect to your Overleaf project via Git and begin exposing files as MCP resources.
uv run python -m src.mainConfigure your MCP client
Add the server to your Claude Desktop config. The command should point to the uv-managed Python environment inside the cloned repository directory.
{
"mcpServers": {
"overleaf": {
"command": "uv",
"args": ["run", "python", "-m", "src.main"],
"cwd": "/path/to/overleaf-mcp-server",
"env": {
"OVERLEAF_TOKEN": "<your-git-integration-token>",
"PROJECT_ID": "<your-overleaf-project-id>"
}
}
}
}Restart your MCP client and sync your project
Restart Claude Desktop. Ask the assistant to list your Overleaf files or sync the project to verify the connection.
Overleaf Examples
Client configuration
Claude Desktop configuration for the Overleaf MCP server using uv as the runtime.
{
"mcpServers": {
"overleaf": {
"command": "uv",
"args": ["run", "python", "-m", "src.main"],
"cwd": "/Users/yourname/overleaf-mcp-server",
"env": {
"OVERLEAF_TOKEN": "<your-git-integration-token>",
"PROJECT_ID": "<your-overleaf-project-id>"
}
}
}
}Prompts to try
Example prompts for AI-assisted LaTeX editing through the Overleaf MCP server.
- "List all files in my Overleaf project"
- "Read the introduction section from main.tex and suggest improvements"
- "Fix the LaTeX compilation errors in sections/methodology.tex"
- "Rewrite the abstract to be more concise and push the changes back to Overleaf"
- "Sync my Overleaf project and show me the list of equations in the paper"Troubleshooting Overleaf
Git authentication fails when syncing from Overleaf
Ensure OVERLEAF_TOKEN is the Git integration token from Overleaf Account Settings, not your login password or a different token. Tokens expire; generate a new one if it was created a long time ago.
PROJECT_ID not found or project fails to clone
Copy the project ID directly from the Overleaf URL: overleaf.com/project/<PROJECT_ID>. Ensure the project has Git integration enabled (available on paid plans) and that your account has access to it.
uv command not found when starting the server
Install uv by running 'curl -LsSf https://astral.sh/uv/install.sh | sh' or 'pip install uv', then ensure the uv binary is on your PATH before restarting the server.
Frequently Asked Questions about Overleaf
What is Overleaf?
Overleaf is a Model Context Protocol (MCP) server that mcp server for overleaf projects. syncs latex files via git, parses sections, equations, and citations, and exposes them to ai clients for assisted paper review, latex fixes, and content generation. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Overleaf?
Follow the installation instructions on the Overleaf GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Overleaf?
Overleaf works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Overleaf free to use?
Yes, Overleaf is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
Overleaf Alternatives — Similar Developer Tools Servers
Looking for alternatives to Overleaf? Here are other popular developer tools servers you can use with Claude, Cursor, and VS Code.
Ecc
★ 188.2kThe agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
Javaguide
★ 155.8kJava 面试 & 后端通用面试指南,覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发
Gemini CLI
★ 104.5kA secure MCP server that wraps the Google Gemini CLI, allowing clients to query Gemini models using local OAuth sessions without requiring an API key. It provides tools for model interaction and diagnostics with built-in protection against command in
Awesome MCP Servers
★ 87.3k⭐ Curated list of Model Context Protocol (MCP) servers - tools that extend Claude Desktop, Cursor, Windsurf, and other MCP clients with custom capabilities.
MCP Servers
★ 86.0kModel Context Protocol Servers
CC Switch
★ 77.5kA cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Gemini CLI & Hermes Agent. Only official website: ccswitch.io
Browse More Developer Tools MCP Servers
Explore all developer tools servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Overleaf 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?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.