Overleaf MCP server
About
allow Tools like copilot, claude desktop, claude code etc. perform CRUD operations on overleaf projects via git int
Details
- Author
- tamirsida
- Categories
- Other, Developer Tools, Communication, Productivity
Jump to
Setup
Install Overleaf MCP server in your MCP client (Claude Desktop, Cursor, Windsurf, and others).
Repository: https://github.com/tamirsida/overleaf_MCP
Follow the installation instructions in the repository README, then restart your MCP client.
AModel Context Protocol (MCP)server that provides full CRUD operations forOverleafLaTeX projects. Enables AI assistants to read, edit, create, and delete files in your Overleaf projects.
14 Tools for Complete Project Management
- Git Integration: Uses Overleaf's Git integration for reliable sync
- Multi-Project Support: Configure and switch between multiple projects
- LaTeX-Aware: Understands document structure for section-based operations
- Auto-Push: All write operations commit and push to Overleaf immediately
- Local Caching: Fast access with local repository cache
- Python 3.10+
- Git
- Overleaf account with Git integration (requires paid plan)
# Clone the repository git clone https://github.com/YOUR_USERNAME/overleaf-mcp.git cd overleaf-mcp # Create virtual environment python3 -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate # Install pip install -e .
git clone https://github.com/YOUR_USERNAME/overleaf-mcp.git cd overleaf-mcp uv venv source .venv/bin/activate uv pip install -e .
-
Open your Overleaf projectin the browser
https://www.overleaf.com/project/YOUR_PROJECT_ID ^^^^^^^^^^^^^^^^
- ClickMenu(top-left)
- ClickGitunder "Sync"
- ClickGenerate token(if not already generated)
- Copy the URL:https://git:YOUR_TOKEN@git.overleaf.com/...
- Extract the token (the part betweengit:and@)
Createoverleaf_config.jsonin the project directory:
{ "projects": { "my-thesis": { "name": "My PhD Thesis", "projectId": "abc123def456", "gitToken": "olp_xxxxxxxxxxxxxxxxxxxx" }, "paper": { "name": "Research Paper", "projectId": "xyz789ghi012", "gitToken": "olp_yyyyyyyyyyyyyyyyyyyy" } }, "defaultProject": "my-thesis" }
export OVERLEAF_PROJECT_ID="your_project_id" export OVERLEAF_GIT_TOKEN="your_git_token"
- macOS:~/Library/Application Support/Claude/claude_desktop_config.json
- Windows:%APPDATA%\Claude\claude_desktop_config.json
- Linux:~/.config/Claude/claude_desktop_config.json
{ "mcpServers": { "overleaf": { "command": "/path/to/overleaf-mcp/.venv/bin/python", "args": ["-m", "overleaf_mcp.server"], "cwd": "/path/to/overleaf-mcp", "env": { "OVERLEAF_CONFIG_FILE": "/path/to/overleaf-mcp/overleaf_config.json", "OVERLEAF_TEMP_DIR": "/path/to/overleaf-mcp/overleaf_cache" } } } }
{ "mcpServers": { "overleaf": { "command": "/Users/username/dev/overleaf-mcp/.venv/bin/python", "args": ["-m", "overleaf_mcp.server"], "cwd": "/Users/username/dev/overleaf-mcp", "env": { "OVERLEAF_CONFIG_FILE": "/Users/username/dev/overleaf-mcp/overleaf_config.json", "OVERLEAF_TEMP_DIR": "/Users/username/dev/overleaf-mcp/overleaf_cache" } } } }
After saving,restart Claude Desktop(Cmd+Q / Ctrl+Q, then reopen).
Add to your Claude Code MCP settings (~/.claude/settings.json):
{ "mcpServers": { "overleaf": { "command": "/path/to/overleaf-mcp/.venv/bin/python", "args": ["-m", "overleaf_mcp.server"], "cwd": "/path/to/overleaf-mcp", "env": { "OVERLEAF_CONFIG_FILE": "/path/to/overleaf-mcp/overleaf_config.json", "OVERLEAF_TEMP_DIR": "/path/to/overleaf-mcp/overleaf_cache" } } } }
Or add per-project in.claude/settings.jsonin your project directory.
Add to your VS Code settings (settings.json):
{ "claude.mcpServers": { "overleaf": { "command": "/path/to/overleaf-mcp/.venv/bin/python", "args": ["-m", "overleaf_mcp.server"], "cwd": "/path/to/overleaf-mcp", "env": { "OVERLEAF_CONFIG_FILE": "/path/to/overleaf-mcp/overleaf_config.json", "OVERLEAF_TEMP_DIR": "/path/to/overleaf-mcp/overleaf_cache" } } } }
Oradd to workspace settings (.vscode/settings.json) for project-specific config.
Once configured, you can ask the AI assistant:
"List all .tex files in my thesis" "Read the content of main.tex" "What sections are in chapter1.tex?"
"Edit main.tex and replace 'teh' with 'the'" "Rewrite the abstract.tex file with this new content: ..." "Update the 'Introduction' section with this new content: ..."
"Create a new file called appendix.tex with a section for supplementary materials" "Add a new bibliography file references.bib"
"Show me the last 10 commits" "What changed since yesterday?" "Sync the project to get latest changes"
"Get the content of the 'Methods' section" "Update the 'Results' section with these findings: ..." "What subsections are in chapter 2?"
┌─────────────────┐ MCP Protocol ┌─────────────────┐ │ AI Assistant │◄───────────────────►│ Overleaf MCP │ │ (Claude, etc.) │ │ Server │ └─────────────────┘ └────────┬────────┘ │ │ Git (HTTPS) ▼ ┌─────────────────┐ │ Overleaf │ │ Git Server │ └─────────────────┘
- Clone/Pull: Server clones or pulls the latest from Overleaf's Git endpoint
- Local Operations: Read/write operations happen on local cache
- Commit/Push: Changes are committed and pushed back to Overleaf
- Real-time Sync: Overleaf reflects changes immediately in the web editor
- Tokens are sensitive: Git tokens provide full read/write access
- Never commit secrets:overleaf_config.jsonis gitignored by default
- Use environment variables: For CI/CD or shared environments
- Token rotation: Regenerate tokens periodically in Overleaf settings
- Ensureoverleaf_config.jsonexists and has valid JSON
- CheckOVERLEAF_CONFIG_FILEpoints to the correct path
"Permission denied" or "Read-only filesystem"
- SetOVERLEAF_TEMP_DIRto an absolute writable path
- Ensure the cache directory exists and is writable
- Verify your git token is correct
- Check if the token has expired (regenerate in Overleaf)
- Ensure you have Git integration enabled (requires paid Overleaf plan)
"Server not appearing in Claude"
- Restart Claude Desktop completely (Cmd+Q / Ctrl+Q)
- Check the config JSON is valid (no trailing commas)
- Verify Python path is correct (use absolute path to venv)
Contributions are welcome! Please open an issue or submit a pull request.
- Overleaffor the Git integration
- Model Context Protocolfor the MCP specification
- Anthropicfor Claude and the MCP SDK
Allows AI assistants to interact with the GitHub API for repository management, code collaboration, and other development tasks.
Collaborative word processor you can use with your agent
An MCP server that equips your AI coding assistant with live, verified Android knowledge — so it builds from official sources, not from memory.
Carryo is a remote MCP server for sharing Claude or ChatGPT-created HTML artifacts as live links.
An MCP server that enables AI assistants to interact with Confluence content through a standardized interface.
Local-first documentation for AI agents. Indexes docs from any git repo into SQLite for offline, instant, private access to up-to-date library documentation.
Publish Markdown or HTML to a clean, shareable link straight from your AI assistant — OAuth, no API keys.
An MCP server for interacting with the esa.io knowledge-sharing platform.
Access the esa.io API to manage your team's knowledge base.
A MCP server for the document sharing service esa.io.
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.





