Oura MCP server

Integrates with the Oura API to retrieve and analyze personal sleep, readiness, and resilience data for health and wellness tracking.
Back to servers
Setup instructions
Provider
Tomek Korbak
Release date
Feb 28, 2025
Language
Python
Stats
18 stars

This MCP server provides access to the Oura API through the Model Context Protocol, allowing language models to query your sleep, readiness, and resilience data from your Oura ring.

Installation and Setup

To use the Oura MCP server, you'll need to:

  1. Install the package
  2. Obtain an Oura API token
  3. Configure your environment

Installing the Package

Install the Oura MCP server package using pip:

pip install oura-mcp-server

Getting an Oura API Token

Before using the server, you'll need to obtain an Oura API token:

  1. Visit the Oura Developer Portal
  2. Create a Personal Access Token
  3. Save this token for the configuration step

Configuration

Setting Up Claude for Desktop

To use the Oura MCP server with Claude for Desktop, update your configuration file:

For macOS:
Edit ~/Library/Application\ Support/Claude/claude_desktop_config.json

For Windows:
Edit %APPDATA%/Claude/claude_desktop_config.json

Add the following configuration:

{
    "mcpServers": {
        "oura": {
            "command": "uvx",
            "args": [
                "oura-mcp-server"
            ],
            "env": {
                "OURA_API_TOKEN": "YOUR_OURA_API_TOKEN"
            }
        }
    }
}

Replace YOUR_OURA_API_TOKEN with the token you obtained from the Oura Developer Portal.

Using the Oura MCP Server

The server provides several tools to query your Oura data.

Available Tools

Date Range Queries

For retrieving data over a specific time period:

  • get_sleep_data(start_date: str, end_date: str): Get sleep data
  • get_readiness_data(start_date: str, end_date: str): Get readiness data
  • get_resilience_data(start_date: str, end_date: str): Get resilience data

Dates must be in ISO format (YYYY-MM-DD).

Today's Data Queries

For quickly accessing today's data:

  • get_today_sleep_data(): Get today's sleep data
  • get_today_readiness_data(): Get today's readiness data
  • get_today_resilience_data(): Get today's resilience data

Example Queries

Once your MCP server is properly configured, you can ask Claude questions like:

  • "What's my sleep score for today?"
  • "Show me my readiness data for the past week"
  • "How was my sleep from January 1st to January 7th?"
  • "What's my resilience score today?"

The server will automatically fetch the relevant data from your Oura account and provide it to Claude for analysis.

Troubleshooting

The server provides human-readable error messages for common issues:

  • Invalid date formats: Make sure dates are in YYYY-MM-DD format
  • API authentication errors: Verify your Oura API token is correct
  • Network connectivity problems: Check your internet connection

If you encounter persistent issues, verify:

  • Your Oura API token is valid and not expired
  • The MCP server is properly configured in the Claude Desktop settings

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "oura" '{"command":"uvx","args":["oura-mcp-server"],"env":{"OURA_API_TOKEN":"YOUR_OURA_API_TOKEN"}}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "oura": {
            "command": "uvx",
            "args": [
                "oura-mcp-server"
            ],
            "env": {
                "OURA_API_TOKEN": "YOUR_OURA_API_TOKEN"
            }
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "oura": {
            "command": "uvx",
            "args": [
                "oura-mcp-server"
            ],
            "env": {
                "OURA_API_TOKEN": "YOUR_OURA_API_TOKEN"
            }
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later