The Jupyter MCP Server enables AI assistants to connect to and control Jupyter Notebooks in real-time through the Model Context Protocol, providing comprehensive notebook management, code execution, and multimodal output handling.
Core Capabilities:
File System Management: Browse files/directories with filtering, pagination, and depth control; search using glob patterns
Kernel Management: List available and running kernels with state, connection details, and specifications; monitor kernel resources and restart kernels as needed
Multi-Notebook Operations: Connect to existing or create new notebooks, switch between multiple notebooks seamlessly, list managed notebooks with status, restart kernels, and disconnect to release resources
Cell-Level Operations: Read cells with metadata and outputs (brief or detailed with pagination), insert new cells (code/markdown) at any position, delete cells individually or in batches, overwrite cell source with diff-style tracking, and execute cells with configurable timeouts and progress streaming
Direct Code Execution: Execute code in kernels without saving to notebooks, including Jupyter magic commands (
%timeit,%pip install), shell commands (!git status), quick calculations, and debuggingMultimodal Support: Handle diverse output types including text, images, and plots; return image data in base64 format when
ALLOW_IMG_OUTPUTis enabledJupyterLab Integration: Access additional commands like run-all-cells and get-selected-cell when running in JupyterLab mode (enabled by default)
AI-Driven Features: Context-aware interactions understanding entire notebook context, smart execution with automatic adjustment based on cell output feedback, and the
jupyter-citeprompt for citing specific cellsFlexible Deployment: Compatible with local Jupyter, JupyterHub, Google Colab, Datalayer hosted notebooks, and works with any MCP client (Claude Desktop, Cursor, Windsurf, etc.)
Provides interaction with Jupyter notebooks running in JupyterLab, allowing adding and executing code cells, creating markdown cells, and interacting with notebook content programmatically.
Offers functionality to download Earth data granules from NASA Earth Data, supporting parameters for folder name, dataset short name, count, temporal range, and bounding box.
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., "@Jupyter MCP Serverinsert a markdown cell at the top with the title 'Data Analysis Report'"
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.
🪐🔧 Jupyter MCP Server
An
Developed by

We Need Your Feedback!
We're actively developing support for JupyterHub and Google Colab deployments. If you're using or planning to use Jupyter MCP Server with these platforms, we'd love to hear from you!
🏢 JupyterHub users: Share your deployment setup and requirements
🌐 Google Colab users: Help us understand your use cases and workflows
Join the conversation in our Community page - your feedback will help us prioritize features and ensure these integrations work seamlessly for your needs.
📖 Table of Contents
Related MCP server: Code Summarizer MCP
🚀 Key Features
⚡ Real-time control: Instantly view notebook changes as they happen.
🔁 Smart execution: Automatically adjusts when a cell run fails thanks to cell output feedback.
🧠 Context-aware: Understands the entire notebook context for more relevant interactions.
📊 Multimodal support: Support different output types, including images, plots, and text.
📚 Multi-notebook support: Seamlessly switch between multiple notebooks.
🎨 JupyterLab integration: Enhanced UI integration like automatic notebook opening.
🤝 MCP-compatible: Works with any MCP client, such as Claude Desktop, Cursor, Windsurf, and more.
Compatible with any Jupyter deployment (local, JupyterHub, ...) and with Datalayer hosted Notebooks.
🔧 MCP Overview
🔧 Tools Overview
The server provides a rich set of tools for interacting with Jupyter notebooks, categorized as follows. For more details on each tool, their parameters, and return values, please refer to the official Tools documentation.
Server Management Tools
Name | Description |
| List files and directories in the Jupyter server's file system. |
| List all available and running kernel sessions on the Jupyter server. |
| Connect to a Jupyter server dynamically without restarting the MCP server. Not available when running as Jupyter extension. Useful for switching servers dynamically or avoiding hardcoded configuration. Read more |
Multi-Notebook Management Tools
Name | Description |
| Connect to a notebook file, create a new one, or switch between notebooks. |
| List all notebooks available on the Jupyter server and their status |
| Restart the kernel for a specific managed notebook. |
| Disconnect from a specific notebook and release its resources. |
| Read notebook cells source content with brief or detailed format options. |
Cell Operations and Execution Tools
Name | Description |
| Read the full content (Metadata, Source and Outputs) of a single cell. |
| Insert a new code or markdown cell at a specified position. |
| Delete a cell at a specified index. |
| Overwrite the source code of an existing cell. |
| Execute a cell with timeout, supports multimodal output including images. |
| Insert a new code cell and execute it in one step. |
| Execute code directly in the kernel, supports magic commands and shell commands. |
JupyterLab Integration
Available only when JupyterLab mode is enabled. It is enabled by default.
When running in JupyterLab mode, Jupyter MCP Server integrates with jupyter-mcp-tools to expose additional JupyterLab commands as MCP tools. By default, the following tools are enabled:
Name | Description |
| Execute all cells in the current notebook sequentially |
| Get information about the currently selected cell |
You can now customize which tools from jupyter-mcp-tools are available using the allowed_jupyter_mcp_tools configuration parameter. This allows you to enable additional notebook operations, console commands, file management tools, and more.
For the complete list of available tools and detailed configuration instructions, please refer to the Additional Tools documentation.
📝 Prompt Overview
The server also supports prompt feature of MCP, providing a easy way for user to interact with Jupyter notebooks.
Name | Description |
| Cite specific cells from specified notebook (like |
For more details on each prompt, their input parameters, and return content, please refer to the official Prompt documentation.
🏁 Getting Started
For comprehensive setup instructions—including Streamable HTTP transport, running as a Jupyter Server extension and advanced configuration—check out our documentation. Or, get started quickly with JupyterLab and STDIO transport here below.
1. Set Up Your Environment
To confirm your environment is correctly configured:
Open a notebook in JupyterLab
Type some content in any cell (code or markdown)
Observe the tab indicator: you should see an "×" appear next to the notebook name, indicating unsaved changes
Wait a few seconds—the "×" should automatically change to a "●" without manually saving
This automatic saving behavior confirms that the real-time collaboration features are working properly, which is essential for MCP server integration.
2. Start JupyterLab
If you are running notebooks through JupyterHub instead of JupyterLab as above, refer to ourJupyterHub setup guide.
3. Configure Your Preferred MCP Client
Next, configure your MCP client to connect to the server. We offer two primary methods—choose the one that best fits your needs:
📦 Using A lightweight and fast method using
uv. Ideal for local development and first-time users.🐳 Using A containerized approach that ensures a consistent and isolated environment, perfect for production or complex setups.
First, install uv:
See more details on uv installation.
Then, configure your client:
On macOS and Windows:
On Linux:
Port Configuration: Ensure the
portin your Jupyter URLs matches the one used in thejupyter labcommand. For simplified config, set this inJUPYTER_URL.Server Separation: Use
JUPYTER_URLwhen both services are on the same server, or set individual variables for advanced deployments. The different URL variables exist because some deployments separate notebook storage (DOCUMENT_URL) from kernel execution (RUNTIME_URL).Authentication: In most cases, document and runtime services use the same authentication token. Use
JUPYTER_TOKENfor simplified config or setDOCUMENT_TOKENandRUNTIME_TOKENindividually for different credentials.Notebook Path: The
DOCUMENT_IDparameter specifies the path to the notebook the MCP client default to connect. It should be relative to the directory where JupyterLab was started. If you omitDOCUMENT_ID, the MCP client can automatically list all available notebooks on the Jupyter server, allowing you to select one interactively via your prompts.Image Output: Set
ALLOW_IMG_OUTPUTtofalseif your LLM does not support mutimodel understanding.
For detailed instructions on configuring various MCP clients—including Claude Desktop, VS Code, Cursor, Cline, and Windsurf — see the Clients documentation.
✅ Best Practices
Interact with LLMs that supports multimodal input (like Gemini 2.5 Pro) to fully utilize advanced multimodal understanding capabilities.
Use a MCP client that supports returning image data and can parse it (like Cursor, Gemini CLI, etc.), as some clients may not support this feature.
Break down complex task (like the whole data science workflow) into multiple sub-tasks (like data cleaning, feature engineering, model training, model evaluation, etc.) and execute them step-by-step.
Provide clearly structured prompts and rules (👉 Visit our Prompt Templates to get started)
Provide as much context as possible (like already installed packages, field explanations for existing datasets, current working directory, detailed task requirements, etc.).
🤝 Contributing
We welcome contributions of all kinds! Here are some examples:
🐛 Bug fixes
📝 Improvements to existing features
🔧 New feature development
📚 Documentation improvements and prompt templates
For detailed instructions on how to get started with development and submit your contributions, please see our Contributing Guide.
Our Contributors
📚 Resources
Looking for blog posts, videos, or other materials about Jupyter MCP Server?
👉 Visit the Resources section in our documentation for more!
If this project is helpful to you, please give us a ⭐️
Made with ❤️ by Datalayer