Overleaf

v1.0.0Developer Toolsstable

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.

latexmcpoverleafoverleaf-mcpresearch
Share:
32
Stars
0
Downloads
0
Weekly
0/5

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

Sync and parse LaTeX files from Overleaf projects for AI-assisted editing.
Review papers and receive LaTeX fixes through natural language interactions.
Generate research content with AI assistance while maintaining project structure.
YounesBensafia

Maintainer

LicenseMIT
Languagepython
Versionv1.0.0
UpdatedMay 12, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx overleaf

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

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
1

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.

2

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 sync
3

Configure 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>
4

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.main
5

Configure 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>"
      }
    }
  }
}
6

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.

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.

Quick Config Preview

{ "mcpServers": { "overleaf": { "command": "npx", "args": ["-y", "overleaf"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

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.

33,000+ ServersFree & Open SourceStep-by-Step Guides