YFinance Trader

The YFinance Trader MCP tool acts as a financial bridge, giving AI assistants like Claude the ability to check the stock market in real-time. In its simplest form, it allows a user to ask their AI about current stock prices, company backgrounds, or the latest trends in popular cryptocurrencies like Bitcoin. Instead of a user having to leave their conversation to manually look up a ticker symbol, the AI uses this tool to fetch the most up-to-date financial data instantly. Moving beyond basic price checks, the tool provides a deep well of corporate and market intelligence. It can retrieve comprehensive company overviews—including metrics like P/E ratios and market caps—and pull historical daily price data to help analyze long-term trends. It also surfaces professional sentiment by fetching analyst recommendations and tracking insider transactions, making it an ideal companion for anyone using an AI to research investment opportunities or understand complex market movements. For developers and AI power users, this tool is specifically optimized for the Claude Desktop environment using the Model Context Protocol. It operates as a Python-based server that exposes structured functions such as `get_stock_quote`, `get_time_series_daily`, and `search_symbol`. These functions return clean JSON data that the LLM can easily parse, reason over, and synthesize into actionable insights. By integrating this server, developers transform a standard language model into a data-driven financial assistant capable of handling precise, real-time market queries with robust error handling.

Category: Finance, Crypto & Payments

Tags: cryptocurrency, finance, market data, stocks, yfinance

Visit YFinance Trader

How to install and configure YFinance Trader

1. Installation To use the YFinance Trader MCP tool, ensure you have Python 3.10 or higher installed. 1. Clone or download the repository. 2. Install the necessary Python dependencies: bash pip install -r requirements.txt

2. Configuration Add the following configuration to your Claude Desktop MCP settings file (typically found at %APPDATA%\Claude\claude_desktop_config.json on Windows or ~/Library/Application Support/Claude/claude_desktop_config.json on macOS): json { "mcpServers": { "yfinance-trader": { "command": "py", "args": ["-3.13", "path/to/your/main.py"] } } } Note: - Replace path/to/your/main.py with the full absolute path to the main.py file in the project directory. - Ensure the Python command (py or python) matches your system's executable. - Restart Claude Desktop after saving the configuration.

3. Available Tools * get_stock_quote: Get real-time stock quote information (price, change, volume, etc.). * get_company_overview: Get detailed company information and key financial metrics (sector, market cap, PE ratio). * get_time_series_daily: Retrieve historical daily price data for a specific symbol. * search_symbol: Search for stocks and other securities by name or ticker. * get_recommendations: Get analyst buy/sell/hold recommendations for a stock. * get_insider_transactions: Track recent insider trading information and transactions.

4. Example Prompts You can use the following queries with Claude: * "What is the current stock price and daily change for AAPL?" * "Can you give me a company overview for Microsoft (MSFT)?" * "Show me the historical price data for Tesla (TSLA) over the last 3 months." * "Search for stocks related to 'NVDA'." * "What are the analyst recommendations for Amazon (AMZN)?" * "Have there been any recent insider transactions for Google (GOOGL)?"

What you can do with YFinance Trader

Use Case 1: Automated Investment Research Reports Problem: Individual investors often spend hours manually gathering data from various financial websites (Yahoo Finance, SEC filings, analyst portals) to create a comprehensive picture of a potential investment. Solution: This MCP allows users to generate a consolidated research report in seconds. By combining get_company_overview, get_recommendations, and get_stock_quote, Claude can synthesize a stock's fundamental health, current valuation, and expert sentiment into a single readable summary. Example: A user asks: "Generate a research brief for NVIDIA (NVDA). Include its current P

E ratio, a summary of recent analyst recommendations, and its performance relative to its 52-week high."

Use Case 2: Tracking "Smart Money" via Insider Transactions Problem: Significant buying or selling by company executives (insiders) can be a powerful indicator of a company's future performance, but this data is often buried in complex regulatory filings. Solution: The get_insider_transactions tool extracts recent trades by directors and officers. This allows users to quickly see if "insiders" are betting on their own company or unloading shares, providing a layer of "conviction" analysis that technical charts alone can't provide. Example: A trader notices a stock is dipping and asks: "Have there been any recent insider buy transactions for Google (GOOGL) that suggest the leadership is confident despite the price drop?"

Use Case 3: Comparative Fundamental Analysis Problem: When choosing between two competitors in the same sector (e.g., Coca-Cola vs. Pepsi), it is difficult to compare their financial metrics side-by-side without manually building a spreadsheet. Solution: Using get_company_overview for multiple symbols, Claude can create a comparison table. It can look at Market Cap, Dividend Yield, and Forward P

E ratios to help the user identify which stock offers better value based on their specific investment criteria. Example: A user asks: "Compare the dividend yield and P/E ratios of Chevron (CVX) and ExxonMobil (XOM). Which one looks more undervalued based on historical averages?"

Use Case 4: Historical Performance Benchmarking Problem: Current price quotes don't tell the whole story; a stock might be at an all-time high or recovering from a massive crash. Users need context on how a stock's current price compares to its recent history. Solution: The get_time_series_daily tool provides historical price data. Claude can use this to calculate volatility, identify trends over the last 3 months, or determine if a stock is currently "oversold" relative to its recent trading range. Example: A user asks: "Based on the…

Key facts

  • Open Source
  • Finance, Crypto & Payments, Web Search & Research
  • cryptocurrency, finance, market data, stocks, yfinance

Part of MCP Servers

Related MCP servers

  • MCP NPX Fetch — Fetch and transform web content into various formats like HTML, JSON, Markdown, or Plain Text.
  • MCP Mempool — Access Bitcoin network data from mempool.space's API for AI agents and applications.
  • MCP Naver News — Search for news articles using the Naver News API. Requires Naver News API credentials.
  • MCP NIF.PT — Query and analyze Portuguese companies using the NIF.PT public API. Supports search by NIF, company name, and city.
  • MCP Options Order Flow Server — A high-performance MCP server for comprehensive options order flow analysis.
  • MCP Open Library — A Model Context Protocol (MCP) server for the Open Library API that enables AI assistants to search for book and…
  • AI Tools
  • Categories
  • Industries
  • CLI Coding Agents
  • MCP Servers
  • MCP Categories