Home / MCP / OneNote MCP Server

OneNote MCP Server

Provides programmatic access to a public OneNote notebook via MCP for navigation, reading, writing, searching, and screenshots.

python
Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
    "mcpServers": {
        "onenote": {
            "command": "python",
            "args": [
                "-m",
                "onenote_mcp"
            ]
        }
    }
}

You can run a Python-based MCP server that automates browsing and interacting with shared OneNote notebooks. It lets AI assistants navigate notebooks, read and write page content, search, and take screenshots, all through MCP-compatible clients.

How to use

You use the OneNote MCP Server by running it locally or integrating it with an MCP host. Start the server in standalone mode to control OneNote directly from your MCP client, or configure a client to launch the server as part of its MCP setup. Once running, you can launch OneNote with a shared notebook URL, browse notebooks, sections, and pages, read or append page content, create new pages, search Across OneNote, and capture screenshots of the current view. The server maintains state across the session so your workflow can be stateful across multiple actions.

How to install

# Prerequisites
Python 3.10 or higher
Playwright
A Python environment with pip
A shared OneNote notebook URL that is accessible without authentication

# Install the package in editable mode
cd onenote-mcp
pip install -e .

# Install Playwright browsers
playwright install
```

# Run the server in standalone mode
python -m onenote_mcp

Configuration and usage notes

To integrate the OneNote MCP Server with an MCP host, use the standard Python command to start the server as shown in the example configuration: you can run the server by invoking Python with the module name for the server.

{
  "type": "stdio",
  "name": "onenote",
  "command": "python",
  "args": ["-m", "onenote_mcp"]
}

Security and access considerations

Only notebooks shared via a public link (no authentication) are supported. Keep in mind that browser automation can be sensitive to UI changes in the web app, so occasional updates to the server may be needed if the OneNote web interface changes.

Troubleshooting

If the server cannot connect to OneNote, verify that the shared notebook URL is accessible without login. If selectors fail during automation, the OneNote UI may have changed and you may need to update the automation selectors in the server code. Check the server logs for error messages to guide your fixes.

Available tools

launch_onenote

Launch the OneNote web app with a shared notebook URL to start a session.

get_all_notebooks

List all notebooks available in the current session.

get_all_sections

List all sections within the currently opened notebook.

get_all_pages

List all pages within the current section.

navigate_to_notebook_by_name

Navigate to a specific notebook by its name.

navigate_to_section_by_name

Navigate to a specific section by name.

navigate_to_page_by_name

Navigate to a specific page by name.

get_current_page_content

Retrieve the content of the currently opened page.

add_content_to_page

Append content to the current page.

create_new_page_with_name

Create a new page with the given name.

search_in_onenote

Search OneNote for specific terms across notebooks, sections, and pages.

take_screenshot

Capture a screenshot of the current OneNote view.

get_onenote_state

Return current state information such as current notebook/section/page and session status.

close_onenote

Terminate the OneNote session and clean up resources.