drio
Open app

yfinance MCP Server

Source

MCP Server for fething yfinance financial data into Claude Desktop

Catalog onlyCatalog onlySTDIO

Overview

The yfinance MCP Server is a Model Context Protocol server designed to fetch financial data from Yahoo Finance and provide it to Claude Desktop for analysis and insights.

To use the server, clone the repository, install the required packages, configure the Claude Desktop settings, and then restart Claude Desktop to access the yfinance server from the menu.

  • Fetch real-time stock prices and historical data - Analyze stock performance over specified periods - Retrieve institutional ownership information - Check analyst price targets for stocks
  1. Querying current stock prices for investment decisions
  2. Analyzing historical stock performance for trend analysis
  3. Evaluating institutional ownership to assess stock stability
  4. Monitoring analyst targets for stock predictions

Add to your AI client

Use these steps to connect yfinance MCP Server in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.

Cursor

Add this to your .cursor/mcp.json file in your project root, then restart Cursor.

.cursor/mcp.json

{
  "mcpServers": {
    "mcp-yfinance-9nate-drake": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-mcp-yfinance-9nate-drake"
      ]
    }
  }
}

Claude Desktop

Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.

~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)

{
  "mcpServers": {
    "mcp-yfinance-9nate-drake": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-mcp-yfinance-9nate-drake"
      ]
    }
  }
}

Claude Code

Add this to your project's .mcp.json file. Claude Code will detect it automatically.

.mcp.json (project root)

{
  "mcpServers": {
    "mcp-yfinance-9nate-drake": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-mcp-yfinance-9nate-drake"
      ]
    }
  }
}

VS Code (Copilot)

Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.

.vscode/mcp.json

{
  "servers": {
    "mcp-yfinance-9nate-drake": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-mcp-yfinance-9nate-drake"
      ]
    }
  }
}

Windsurf

Add this to your Windsurf MCP config file, then restart Windsurf.

~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "mcp-yfinance-9nate-drake": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-mcp-yfinance-9nate-drake"
      ]
    }
  }
}

Cline

Open Cline settings, navigate to MCP Servers, and add this server configuration.

Cline MCP Settings (via UI)

{
  "mcpServers": {
    "mcp-yfinance-9nate-drake": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-mcp-yfinance-9nate-drake"
      ]
    }
  }
}

FAQ

What are the system requirements?

You need Python 3.10 or higher and Claude Desktop to use this server.

How do I install the yfinance MCP Server?

Clone the repository and install the required packages listed in the instructions.

Can I customize the server?

Yes! You can modify the server.py file to customize the functionality according to your needs.7:["$","div",null,{"className":"container mx-auto flex flex-col gap-4","children":["$L26","$L27",["$","$L28",null,{"currentProject":{"id":370,"uuid":"4c19ce96-d8fe-4bce-b23c-97cc5098653a","name":"mcp-yfinance","title":"yfinance MCP Server","description":"MCP Server for fething yfinance financial data into Claude Desktop","avatar_url":"https://avatars.githubusercontent.com/u/58997975?v=4","created_at":"2024-12-13T13:21:47.508Z","updated_at":"2024-12-13T15:09:08.745Z","status":"created","author_name":"9nate-drake","author_avatar_url":"https://avatars.githubusercontent.com/u/58997975?v=4","tags":"ai,mcp,claude,modelcontextprotocol","category":"research-and-data","is_featured":false,"sort":1,"url":"https://github.com/9nate-drake/mcp-yfinance","target":"_self","content":"$29","summary":"$2a","img_url":null,"type":null,"metadata":null,"user_uuid":null,"tools":null,"sse_url":null,"sse_provider":null,"sse_params":null,"is_official":false,"server_command":null,"server_params":null,"server_config":null,"allow_call":false,"is_innovation":false,"is_dxt":false,"dxt_manifest":null,"dxt_file_url":null,"is_audit":false},"randomProjects":[],"currentServerKey":"$undefined"}]]}]