MCP Baostock Server logo

MCP Baostock Server

by HuggingAGI

Queries BaoStock for Chinese stock, index, financial, dividend, industry, and valuation data through MCP.

Install MCP Baostock Server

Run the project’s own setup commands, in order.

Setup steps from the project

HuggingAGI/mcp-baostock-server installs with its own steps rather than a config we can generate, so these are copied as-is. Follow them in order and run the commands in a terminal. Source: github.com

  1. 1. Start the server
    uv run mcp-baostock-server
    

Overview

HuggingAGI/mcp-baostock-server exposes BaoStock-backed Chinese stock-market data through MCP tools. It covers stock profiles, historical K-line records, industry classifications, dividends, quarterly financial indicators, index data, and valuation metrics. Reach for it when an MCP client needs structured Chinese market data for lookup or analysis.

Use cases

  • Query Chinese stock basic information
  • Retrieve adjusted historical K-line data
  • Compare quarterly financial indicators
  • Review dividend and distribution records
  • Analyze index and valuation data

Key features

  • Stock basic information queries
  • Historical K-line data retrieval
  • Industry classification lookup
  • Dividend and distribution data
  • Quarterly financial indicators
  • Index and valuation data

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

33/33 checks healthy over the last 118d

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars118Stargazers on the source repository.
Last commit8mo agoMost recent push to the default branch.
Directory activity2 viewsConfig copies, upvotes, and views on AllMCPs.

How MCP Baostock Server works

What HuggingAGI/mcp-baostock-server does

HuggingAGI/mcp-baostock-server connects MCP clients with BaoStock data for the Chinese stock market. Its interfaces cover several common research tasks: retrieving a company’s basic information, requesting historical K-line records, checking industry classifications, reviewing dividend and distribution records, and examining financial or valuation indicators.

The available financial indicators include quarterly profitability, operating-capacity, and growth measures. The server also supports historical index market data, including examples based on the CSI 300.

This places the project in the 💰 Finance & Fintech category. It is suited to data lookup and analysis workflows that need BaoStock’s Chinese equity and index datasets through an agent-facing interface.

How it works

An MCP-compatible client starts the server and sends requests for the supported BaoStock data categories. Queries can identify securities with exchange-qualified codes such as sh.600519 or sz.000001, and historical requests can specify a date range. The examples also show daily K-line retrieval with a forward-adjustment option.

Requests can target a particular reporting period, such as a quarter or calendar year. For example, an agent can ask for a company’s second-quarter operating indicators, a year’s dividend details, or index daily prices across a selected period. The returned data can then support comparisons or further analysis in the client.

Setup and configuration

HuggingAGI/mcp-baostock-server requires Python 3.10 or newer, the baostock package, and pandas. The README provides this launch command:

bash
uv run mcp-baostock-server

The repository includes a demonstration image and Python-based interface examples, but does not provide client-specific setup instructions.

Tools and capabilities

The documented capability areas are:

  • Query stock basic information, including listing dates and industry details.
  • Retrieve historical K-line data for a selected security, date range, frequency, and adjustment approach.
  • Look up industry classification information.
  • Retrieve dividend and distribution records for a specified year.
  • Query quarterly profitability indicators.
  • Query quarterly operating-capacity indicators.
  • Query quarterly growth indicators.
  • Retrieve historical index market data.
  • Examine valuation indicators such as price-to-earnings and price-to-book ratios.

Limitations and notes

HuggingAGI/mcp-baostock-server is documented around BaoStock and Chinese stock-market datasets. It also does not state update frequency, historical coverage limits, rate limits, or error-handling behavior.

Results should be interpreted according to the requested security code, period, frequency, and adjustment settings. The examples use Chinese-language prompts and exchange-prefixed symbols, so callers should provide identifiers in the format expected by BaoStock.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about MCP Baostock Server

HuggingAGI/mcp-baostock-server is an MCP server that connects AI clients to BaoStock-backed Chinese stock-market data. Its main tools cover stock basics, historical K-line records, industry classification, dividends, quarterly profitability, operating and growth metrics, index quotes, and valuation indicators. It requires Python 3.10+, baostock, and pandas.

Run `uv run mcp-baostock-server` after installing or making available Python 3.10+, `baostock`, and `pandas`.

It can retrieve stock profiles, historical K-line data, industry classifications, dividend records, quarterly profitability, operating-capacity and growth indicators, index data, and valuation metrics such as price-to-earnings and price-to-book ratios.

Yes. It supports historical K-line requests over a specified date range, including daily data and a forward-adjustment option shown in the examples. The documented examples use exchange-prefixed BaoStock symbols such as `sh.600519` and `sz.000001`.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewMCP Baostock Server AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/huggingagi-mcp-baostock-server?style=directory)](https://allmcps.com/mcp/huggingagi-mcp-baostock-server)
HTML Embed
<a href="https://allmcps.com/mcp/huggingagi-mcp-baostock-server"><img src="https://allmcps.com/api/badge/huggingagi-mcp-baostock-server?style=directory" alt="MCP Baostock Server on AllMCPs" /></a>