Skip to main content
Glama
guobo2421-ui

StockMCP

by guobo2421-ui

StockMCP

AI-Powered Stock Market Analysis MCP Server

Badges

License Python MCP GitHub release GitHub stars

Related MCP server: MCP YFinance Stock Server

Introduction

StockMCP is an open-source Model Context Protocol (MCP) server that enables AI assistants such as Claude Desktop and Cursor to access real-time U.S. stock market data through a rich set of financial analysis tools.

StockMCP combines market data, SEC filings, company fundamentals, valuation metrics, analyst forecasts, options data, financial health analysis, and watchlist screening into one unified MCP server.

It is designed for AI-powered investment research using Claude Desktop, Cursor, and other MCP-compatible AI clients.

Current Version

StockMCP v1.0

Initial stable release including:

  • Financial analysis

  • Company reports

  • Watchlist screening

  • Forecasts

  • Options analysis

Highlights

  • Real-time U.S. stock market data

  • SEC financial statements (up to 8 quarters)

  • Comprehensive company reports

  • Financial ratio and TTM analysis

  • Profitability, liquidity, leverage, valuation and financial health scoring

  • Automated company comparison and ranking

  • Watchlist screening and ranking

  • Analyst forecasts

  • Options chain and implied volatility

  • AI-ready tools for Claude Desktop, Cursor and other MCP clients

Features

Market Data

  • Real-time stock prices

  • Historical price data

  • Company information

Financial Analysis

  • SEC quarterly financial statements

  • TTM income statement, balance sheet and cash flow

  • Financial ratios

  • Financial health scoring and analysis

Investment Research

  • Company reports

  • Stock comparison

  • Watchlist screening

  • Analyst forecasts

Options Analysis

  • Option expiration dates

  • Calls and puts

  • Implied volatility

  • Open interest analysis

Supported AI Clients

Client

Supported

Claude Desktop

Cursor

VS Code + MCP

Planned

Windsurf

Planned

Quick Start

Install

git clone https://github.com/guobo2421-ui/StockMCP.git
cd StockMCP

python -m venv .venv

# Windows
.venv\Scripts\activate

# macOS / Linux
source .venv/bin/activate

pip install -r requirements.txt

python server.py

Example AI Queries

Analyze Costco's financial health.

Financial Health Analysis

Compare Apple, Microsoft, Nvidia, Google and Broadcom.

Company Comparison

Generate a complete company report for Costco.

Company Report

Find the healthiest company in my watchlist.

Screening Companies

Rank these companies by financial quality.

Rank Companies

Show Tesla's nearest option expiration.

Option Expiration Analysis

Summarize Nvidia's latest news.

Summarize Company News

Evaluate Microsoft's financial health.

Evaluate Company Financial Health

Which company has the strongest balance sheet?

Find Strongest Balance Sheet

Forecast Amazon's revenue and earnings.

Revenue and Earnings Forecast

Documentation

Architecture Diagram

                         ┌─────────────────────┐
                         │   AI Clients        │
                         │ Claude / Cursor     │
                         └──────────┬──────────┘
                                    │
                                    ▼
                         ┌─────────────────────┐
                         │     server.py       │
                         │  MCP Server Entry   │
                         │                     │
                         │  imports tools/*    │
                         └──────────┬──────────┘
                                    │
                                    ▼
              ┌────────────────────────────────────────┐
              │              tools/                    │
              │          MCP Tool Layer                │
              │                                        │
              │  stock.py        company.py            │
              │  financials.py   forecast.py           │
              │  market.py       news.py               │
              │  options.py      screening.py          │
              │  watchlist.py                          │                           
              │                                        │
              │  @mcp.tool()                           │
              └──────────────────┬─────────────────────┘
                                 │
                                 ▼
              ┌──────────────────────────────────────────┐
              │             services/                    │
              │          Business Logic Layer            │
              │                                          │
              │  yahoo.py           market_data.py       │
              │  financial_data.py  financial_ttm.py     │
              │  forecast_data.py   sec_financial_data.py│
              │                                          │
              │  Data retrieval                          │
              │  Calculations                            │
              │  Financial analysis                      │
              └──────────────────┬───────────────────────┘
                                 │
                    ┌────────────┼────────────┐
                    ▼            ▼            ▼
             ┌──────────┐ ┌──────────┐ ┌──────────┐
             │ Yahoo    │ │ SEC      │ │ Other    │
             │ Finance  │ │ Company  │ │ API      │
             │          │ │ Facts    │ │          │
             └──────────┘ └──────────┘ └──────────┘

Data Sources

StockMCP uses:

  • Yahoo Finance for market data and price information

  • SEC CompanyFacts API for financial statements

  • Analyst estimates for forecasts

  • Options market data for derivatives analysis

Configuration

Some advanced features may require API configuration depending on the selected data providers.

See:

  • docs/INSTALL.md

  • docs/DEVELOPMENT.md

for environment variables and setup details.

Development

See the Development Guide for:

  • Project structure

  • Adding new MCP tools

  • Extending financial analysis modules

  • Running tests

Roadmap

Completed

  • ✅ Real-time market data

  • ✅ Company fundamentals

  • ✅ SEC financial statements

  • ✅ Financial ratios

  • ✅ Financial health analysis

  • ✅ Company reports

  • ✅ Watchlist screening and financial ranking

  • ✅ Analyst forecasts

  • ✅ Options analysis

Planned

  • Technical indicators

  • Portfolio analysis

  • ETF analysis

  • Dividend analysis

  • Economic indicators

  • Insider trading analysis

License

StockMCP is released under the MIT License.

A
license - permissive license
-
quality - not tested
A
maintenance

Maintenance

Maintainers
Response time
Release cycle
1Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    -
    quality
    F
    maintenance
    Enables AI assistants to access real-time financial data, historical stock prices, company information, financial statements, options data, market news, and analyst recommendations through Yahoo Finance. Built with FastMCP v2 for efficient HTTP streaming and comprehensive market analysis tools.
    3
  • A
    license
    -
    quality
    D
    maintenance
    Enables AI agents to retrieve real-time stock data, manage watchlists, and perform comprehensive technical analysis using Yahoo Finance API. Provides 18+ tools for stock price tracking, trend analysis, volatility assessment, and financial indicators through MCP integration.
    MIT
  • F
    license
    A
    quality
    D
    maintenance
    Provides financial data from Yahoo Finance via MCP, enabling AI agents to access real-time stock info, historical prices, financial statements, and market analysis.
    10
    12

View all related MCP servers

Related MCP Connectors

  • The financial MCP for AI agents - 90+ financial tables, SEC filings, signals, alt-data.

  • Real SEC, 13F, insider, congress & macro data your AI agent can cite. Hosted MCP, 24 tools.

  • Twelve Data MCP: real-time & historical market data (stocks, crypto, forex, etc).

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/guobo2421-ui/StockMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server