A comprehensive Model Context Protocol (MCP) server that provides advanced LaTeX file creation, editing, and management capabilities for Large Language Models and AI assistants.
Config is the same across clients — only the file and path differ.
{
"mcpServers": {
"latex-server": {
"env": {
"LATEX_SERVER_BASE_PATH": "/path/to/your/latex/files"
},
"args": [
"--directory",
"/path/to/mcp-latex-server",
"run",
"latex_server.py"
],
"command": "uv"
}
}
}Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
A Model Context Protocol (MCP) server for LaTeX file creation, editing, validation, and compilation. Built with FastMCP and Pydantic for type-safe, structured output.
No automated test available for this server. Check the GitHub README for setup instructions.
Five weighted categories — click any category to see the underlying evidence.
No known CVEs.
No package registry to scan.
Be the first to review
Have you used this server?
Share your experience — it helps other developers decide.
Sign in to write a review.
Others in writing / developer-tools
A Model Context Protocol (MCP) server and CLI that provides tools for agent use when working on iOS and macOS projects.
XcodeBuildMCP provides tools for Xcode project management, simulator management, and app utilities.
Asynchronous coordination layer for AI coding agents: identities, inboxes, searchable threads, and advisory file leases over FastMCP + Git + SQLite
MCP server for accessing Figma plugin console logs and screenshots via Cloudflare Workers or local mode
MCP Security Weekly
Get CVE alerts and security updates for Mcp Latex Server and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.
A Model Context Protocol (MCP) server for LaTeX file creation, editing, validation, and compilation. Built with FastMCP and Pydantic for type-safe, structured output.
.tex files within a secure base directorypdflatex, xelatex, or lualatexlatex:// URIsgit clone https://github.com/RobertoDure/mcp-latex-server
cd mcp-latex-server
uv pip install -e .
git clone <repository-url>
cd mcp-latex-server
python -m venv .venv
# Windows
.venv\Scripts\activate
# macOS/Linux
source .venv/bin/activate
pip install -e .
python quick_setup.py
This checks Python version, installs dependencies, verifies the server imports correctly, and optionally configures Claude Desktop.
The server uses a single environment variable:
| Variable | Description | Default |
|---|---|---|
LATEX_SERVER_BASE_PATH | Root directory for all file operations | . (current directory) |
All file paths passed to tools are resolved relative to this base directory. Access outside it is denied.
Add to your claude_desktop_config.json:
%APPDATA%\Claude\claude_desktop_config.json~/Library/Application Support/Claude/claude_desktop_config.json~/.config/Claude/claude_desktop_config.json{
"mcpServers": {
"latex-server": {
"command": "uv",
"args": [
"--directory",
"/path/to/mcp-latex-server",
"run",
"latex_server.py"
],
"env": {
"LATEX_SERVER_BASE_PATH": "/path/to/your/latex/files"
}
}
}
}
Add to .vscode/mcp.json in your workspace:
{
"servers": {
"latex-server": {
"command": "uv",
"args": [
"--directory",
"/path/to/mcp-latex-server",
"run",
"latex_server.py"
],
"env": {
"LATEX_SERVER_BASE_PATH": "${workspaceFolder}"
}
}
}
}
create_latex_fileCreate a new LaTeX document from parameters.
| Parameter | Type | Default | Description |
|---|---|---|---|
file_path | str | required | Path for the new .tex file |
document_type | article|report|book|letter|beamer|minimal | article | Document class |
title | str | "" | Document title |
author | str | "" | Document author |
date | str | \today | Document date |
content | str | "" | Body content |
packages | list[str] | [] | Extra LaTeX packages |
geometry | str | "" | Geometry settings (e.g. margin=1in) |
create_from_templateCreate a document from a bundled template.
| Parameter | Type | Default | Description |
|---|---|---|---|
file_path | str | required | Path for the new .tex file |
template | article|beamer|report | article | Template name |
edit_latex_fileEdit an existing LaTeX file.
| Parameter | Type | Default | Description |
|---|---|---|---|
file_path | str | required | Path to the file |
operation | `replace|insert_before |