get_section_content
Get content of a specific section
Edit a LaTeX paper on Overleaf a section at a time: list the sections, pull one by its title, and replace just that section with a commit message attached.
LABSCO SUMMARY
The section tools read a paper the way its authors think about it, and write_section replaces one named section rather than the file, so an agent rewriting the introduction cannot quietly take the results with it. Every write carries a commit message, which leaves a history in Overleaf that a human can walk back. Projects are configured into the server rather than discovered, so adding a new paper is a configuration change and not a call.
A server over an Overleaf project through its Git access, with LaTeX-aware reads — sections parsed out of a file rather than only whole files.
OVERLEAF_PROJECT_ID and OVERLEAF_GIT_TOKEN for the project you intend to edit; writes go out over Overleaf's Git access, so the token has to be one that can push. MIT.
One command plus a key — npx -y @mjyoo2/overleaf-mcp, then supply credentials
USE CASES
List the sections by title, read the one being revised, and write it back on its own — the surrounding sections are untouched, and the commit message travels with the change.
See which projects the server is configured for, list the files in one filtered to the extension you care about, and read the project status before changing anything.
Read an existing file to match its conventions, then write the new one with a commit message that explains it in the project history.
Counted once with only startup setup. Other versions, modes or optional credentials may expose a different list.
get_section_contentGet content of a specific section
get_sectionsGet all sections from a LaTeX file
list_filesList files in an Overleaf project
list_projectsList all configured Overleaf projects
read_fileRead a file from an Overleaf project
status_summaryGet a comprehensive project status summary
write_fileWrite content to a file in an Overleaf project and push to Overleaf
write_sectionReplace a single section in a LaTeX file and push to Overleaf. Safer than write_file for targeted edits — only the named section is replaced, leaving the rest of the file untouched.
BEFORE YOU INSTALL
8 tools when we connected.
Both documented setups run the server on your machine.
CONTEXT COST
Rated by the size of the 8 tool definitions that ride along on every turn, not by how many there are
INSTALLATION
npx -y @mjyoo2/overleaf-mcp{
"mcpServers": {
"overleaf": {
"command": "npx",
"args": [
"-y",
"@mjyoo2/overleaf-mcp"
],
"env": {
"OVERLEAF_PROJECT_ID": "<YOUR_OVERLEAF_PROJECT_ID>",
"OVERLEAF_GIT_TOKEN": "<YOUR_OVERLEAF_GIT_TOKEN>"
}
}
}
}{
"mcpServers": {
"overleaf": {
"command": "cmd",
"args": [
"/c",
"npx",
"-y",
"@mjyoo2/overleaf-mcp"
],
"env": {
"OVERLEAF_PROJECT_ID": "<YOUR_OVERLEAF_PROJECT_ID>",
"OVERLEAF_GIT_TOKEN": "<YOUR_OVERLEAF_GIT_TOKEN>"
}
}
}
}