MCP server for LaTeX: connect Claude, ChatGPT, Cursor and Antigravity

The assistant works directly on the files of the project, with no copying and pasting between the chat and TexWaller. Follow every edit live in the editor and choose whether it gets write access or only read access.

Add it to your assistant

Claude

Web and desktop

  1. Open Settings › Connectors and choose Add custom connector.
  2. Paste the server URL and press Connect.
Server URL
https://api.texwaller.com/mcp

Claude Code

  1. Run the command below in your terminal.
  2. In Claude Code, run /mcp and sign in.
bash
claude mcp add --transport http texwaller https://api.texwaller.com/mcp

ChatGPT

Web and desktop

  1. Open Settings › Apps › Advanced settings and turn on developer mode.
  2. Create an app with the server URL and OAuth authentication.
  3. In each chat, turn TexWaller on from the + menu.
Server URL
https://api.texwaller.com/mcp

Codex

  1. Run the commands below in your terminal.
  2. The second one opens the browser: sign in to TexWaller and allow the connection.
bash
codex mcp add texwaller --url https://api.texwaller.com/mcp codex mcp login texwaller

Cursor

  1. Press Add to Cursor, or copy the config below.
  2. In Settings › Tools & MCP, press Connect and sign in.
Add to Cursor
~/.cursor/mcp.json
{ "mcpServers": { "texwaller": { "url": "https://api.texwaller.com/mcp" } } }

Antigravity

  1. In the agent panel, open Manage MCP Servers › View raw config.
  2. Add the config below and save.
mcp_config.json
{ "mcpServers": { "texwaller": { "serverUrl": "https://api.texwaller.com/mcp" } } }

VS Code

  1. Press Install in VS Code, or copy the config below. It needs the agent mode of GitHub Copilot Chat.
  2. Start the server from the MCP Servers view and sign in.
Install in VS Code
.vscode/mcp.json
{ "servers": { "texwaller": { "type": "http", "url": "https://api.texwaller.com/mcp" } } }

Ollama (local models)

  1. Ollama runs the model on your computer; the agent you write in connects it to TexWaller. Choose a model that can use tools.
  2. Start Ollama with a context of at least 64,000 tokens: with less, the model loses track of the tools.
bash
OLLAMA_CONTEXT_LENGTH=64000 ollama serve

Claude Code

  1. Add TexWaller as in the Claude card.
  2. Start Claude Code on a local model with the command below.
bash
ollama launch claude

Codex

  1. Add TexWaller as in the ChatGPT card.
  2. Start Codex on a local model with the command below.
bash
codex --oss -m gpt-oss:20b

VS Code

  1. Add TexWaller as in the VS Code card.
  2. Install the Ollama extension and pick a local model in the model picker of the chat, in agent mode.

Other agents

  1. Any client that connects to remote MCP servers (Streamable HTTP) with OAuth works.
  2. Add the server URL in its MCP settings and sign in when it asks you to.
Server URL
https://api.texwaller.com/mcp

What the assistant can do

Read

  • List your projects and their files
  • Read text files and images
  • Search the files
  • Read the errors and warnings of the last compilation you ran

Edit, if you allow it

  • Edit, create, move and delete files
  • Replace a text in many files
  • Add small files such as images and PDFs
  • Create Beamer or PowerPoint presentations
  • Save a version of the project

Not possible

  • Compile or see the PDF
  • Share the project or restore a version
  • Change the settings

What the TexWaller MCP server is

MCP, the Model Context Protocol, is the standard AI apps use to connect to external services. TexWaller is an online LaTeX editor with an MCP server: add its URL to Claude, ChatGPT, Cursor or another agent, sign in, and the app can work on the files of your projects.

You keep writing in the AI app you already use, with your own account or subscription. The assistant opens the .tex and .bib files of the project, edits them where they are and tells you what it changed. In TexWaller the edits appear in the editor as they happen, for you and for your co-authors.

What to ask your assistant

Type the request in the AI app and name the project when you have several.

  • In my TexWaller thesis project, rewrite the introduction to make it more concise.
  • Read the errors of the project's last compilation and fix them.
  • Create a ten-slide Beamer presentation based on chapter 3.
  • Find every figure without a caption and add one.
  • Rename the label tab:results in all the files of the project.
  • Save a version of the project called Before the review.

You decide what the assistant can do

Read-only or read and write

When the app connects, a TexWaller page asks for your permission. Editing files is a box you can untick, to let the assistant read without changing anything.

You see who is asking

The consent page names the app that asks for access and marks the recognised ones as verified.

Only your projects

The app works on your behalf: it sees the projects you see and edits only the ones you can edit.

Every edit, live

The changes show up in the editor while the assistant works, and you can undo them or go back to a saved version.

Disconnect at any time

In Settings, under AI Chat, the MCP connector lists the connected apps: Disconnect removes an app's access immediately.

Use a local model with Ollama

Ollama runs AI models on your computer. An agent such as VS Code, Codex, Cursor or Claude Code passes your requests to the model and reaches your TexWaller projects through the MCP server, so the edits still appear live in the editor.

With a local model the text of your files is processed on your computer instead of by an outside provider, and you don't pay by usage. In return, local models are less capable than the best cloud models and slower, especially on long documents.

  • The model must be able to call tools: without tool calling it can chat, but not read or edit your projects.
  • It needs a context window of at least 64,000 tokens, more than Ollama's default on many computers.
  • If your computer is not powerful enough, Ollama's cloud models are used in the same way.
See the steps for Claude Code, Codex and VS Code in the Ollama card

Questions about AI assistants and LaTeX

Can Claude edit my LaTeX files directly?
Yes. Add TexWaller as a custom connector in Claude, or with one command in Claude Code, and sign in. Claude then reads and edits the files of your TexWaller projects, with no copying and pasting between the chat and the editor.
Can I use ChatGPT on a LaTeX project?
Yes. In ChatGPT turn on developer mode, create an app with the TexWaller server URL and OAuth authentication, and turn TexWaller on in the chat. With Codex, two commands in the terminal are enough.
Does it work with Cursor and VS Code?
Yes. Cursor and VS Code add the server with one click from this page. VS Code needs the agent mode of GitHub Copilot Chat. Any other client that connects to remote MCP servers with OAuth works too.
Can the assistant compile the document or fix compile errors?
It cannot compile or see the PDF: you compile in TexWaller, in your browser. It can read the errors and warnings of the last compilation you ran, open the files at those lines and fix them.
Can I give the assistant read-only access?
Yes. On the consent page untick file editing: the assistant can list your projects, read and search the files, but not change them. To change the permission later, disconnect the app and connect it again.
Can I use a local model with Ollama?
Yes, through an agent such as VS Code, Codex, Cursor or Claude Code. Choose a model that can call tools and give it a context window of at least 64,000 tokens.
How do I disconnect an app?
In TexWaller open Settings, then AI Chat, and under MCP connector press Disconnect next to the app.
Is the MCP connector free?
Yes. The connector is part of TexWaller, which is free. You use the AI app with your own account or subscription.

More in TexWaller

Let your assistant work on the real files

Create a free account, add the server URL to your AI app and open a project.

Start for free