read_notebook_cellsLABSCO SUMMARY
The notebook edits itself while you talk about it.
Reading a notebook to a model usually means pasting cells and losing the structure. Addressing cells by index and type keeps the file as the source of truth, and executing in place means the output you discuss is the output that is saved.
What it is
Notebook file operations over MCP: read cells with a type filter, add cells at any position, execute one cell or every code cell, and read a notebook's metadata and statistics.
What you get
- Cells read from an .ipynb file, filterable to code, markdown or raw
- A new cell inserted at a chosen position or appended, with its own metadata
- One cell executed by index, against a named kernel, with a timeout
- Every code cell executed in order, with a stop-on-error option and a per-cell timeout
- Notebook metadata and statistics
- Progress reporting on the long runs, so a whole-notebook execution is not silent
Requirements
uv, and a current fastmcp, launched against main.py by absolute path. Cell execution runs Python directly through a subprocess, so run only notebooks you trust or put the server in a sandbox.
Setup effort
Build from source — git clone https://github.com/shwetalsoni/jupyter-notebook-mcp-server
USE CASES
Understanding a notebook someone handed you
Read the markdown cells first for the narrative, then the code.
Adding a step in the middle of an analysis
Insert the cell at the position it belongs, rather than appending and reordering by hand.
Re-running one cell after a fix
Execute that cell by index against the kernel it needs, with a timeout set.
Checking a notebook still runs end to end
Execute every code cell in order and stop at the first error.
Sizing up a file before opening it
Read the metadata and cell counts to see what you are dealing with.
5 tools
Listed in project docs. Your client may show a different list.
add_cell_to_notebookexecute_notebook_cellexecute_entire_notebookget_notebook_infoBEFORE YOU INSTALL
What to know first
Tools you get
5 tools named in the project's documentation.
Requires
uv on PATH
Where it runs
All 3 documented clients run the server on your machine.
INSTALLATION
Connect your client
You clone and build this one yourself.
Server setup
Make sure uv is installed.
git clone https://github.com/shwetalsoni/jupyter-notebook-mcp-serverIn the configuration under MCP Clients, <YOUR_ABSOLUTE_PATH_TO_JUPYTER_MCP> is the absolute path of this clone (main.py sits at its root).
MCP Clients
Cursor, Claude Desktop, Any MCP client
{
"mcpServers": {
"jupyter-notebook": {
"command": "uv",
"args": [
"run",
"--with",
"fastmcp>=2.8.1",
"python",
"<YOUR_ABSOLUTE_PATH_TO_JUPYTER_MCP>/main.py"
]
}
}
}