Unofficial Overleaf MCP Server
Provides tools for managing Overleaf projects, including creating projects, listing and manipulating files, real-time document editing via Operational Transformation, and triggering LaTeX compilation for PDF download.
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., "@Unofficial Overleaf MCP ServerCreate a new Overleaf project named 'test'."
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.
Unofficial Overleaf MCP Server
An unofficial Model Context Protocol (MCP) server that provides AI agents with the ability to interact with Overleaf projects directly. This server allows agents to create projects, list files, read contents, manage files, and securely edit documents in real-time using Overleaf's native Operational Transformation (ShareJS) WebSocket protocol.
Features
Project Management: Create new Overleaf projects natively.
File System (CRUD): List, upload, create, move, and delete files or folders within an Overleaf project.
Real-Time Document Editing: Edits files natively without full ZIP downloads. Utilizes a reverse-engineered Socket.IO 0.9 shim and the
diff-match-patchlibrary to translate semantic edits into precise ShareJStext0Operational Transformation (OT) updates.Compilation: Trigger server-side LaTeX compilation and download the resulting PDF.
Related MCP server: claudeleaf
Prerequisites
Node.js (v18+)
An active Overleaf account.
Configuration
This MCP Server authenticates to Overleaf using a session cookie. You must provide the OVERLEAF_COOKIE environment variable to run the server.
Log into your Overleaf account in your browser.
Open the Developer Tools (F12) -> Application / Storage -> Cookies.
Find the
overleaf_session2cookie.Set the value as an environment variable (or include it in your MCP configuration).
Adding to Antigravity IDE / Gemini
To use this server directly inside the Antigravity IDE or Gemini agents, add the following configuration to ~/.gemini/config/mcp_config.json:
{
"mcpServers": {
"overleaf": {
"command": "node",
"args": [
"/absolute/path/to/unofficial-overleaf-mcp-server/build/index.js"
],
"env": {
"OVERLEAF_COOKIE": "overleaf_session2=s%3A..."
}
}
}
}Available MCP Tools
overleaf_create_project(projectName)overleaf_list_files(projectId)overleaf_read_file(projectId, filePath)overleaf_edit_file(projectId, filePath, targetContent, replacementContent)overleaf_create_doc(projectId, name, parentFolderPath)overleaf_create_folder(projectId, name, parentFolderPath)overleaf_upload_file(projectId, filePath, folderId)overleaf_move_entity(projectId, path, newParentFolderPath)overleaf_delete_entity(projectId, path)overleaf_compile_and_download(projectId, rootDocId, outputPath)
Security Note
This server requires your Overleaf session cookie to operate. Do not commit your session cookie or any specific project IDs into version control.
Build
npm install
npm run buildUsage
npm startMaintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityCmaintenanceA real-time MCP server that enables AI coding agents to read, write, and compile LaTeX projects in self-hosted Overleaf instances via native OT protocol.Last updated302AGPL 3.0
- Alicense-qualityCmaintenanceEnables Claude and AI agents to read and edit Overleaf documents in real time, with support for project listing, document manipulation, LaTeX compilation, and live collaboration.Last updated315MIT
- Alicense-qualityBmaintenanceEnables AI agents to read, edit, and compile LaTeX documents in Overleaf projects with tracked changes via the Model Context Protocol.Last updatedMIT
- Alicense-qualityCmaintenanceEnables AI assistants to read, edit, and compile LaTeX projects on Overleaf using session cookie authentication, bypassing the need for a paid plan.Last updatedMIT
Related MCP Connectors
Edit your Overleaf LaTeX projects from Claude and ChatGPT; every change is a real Git commit.
The team layer for AI coding agents: shared contracts, collision alerts, E2EE sessions.
Persistent docs and memory for AI agents — read, write, organize & search a shared workspace.
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/n-qber/unofficial-overleaf-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server