Home / MCP / AKShare MCP Server
Provides access to Chinese and global financial data via AKShare through MCP for Claude Desktop and other clients.
Configuration
View docs{
"mcpServers": {
"akshare_mcp": {
"command": "uv",
"args": [
"--directory",
"/path/to/akshare_mcp_server",
"run",
"akshare-mcp"
],
"env": {
"AKSHARE_API_KEY": "<your_api_key_if_needed>"
}
}
}
}You run the AKShare MCP Server to access comprehensive financial data analysis capabilities via the MCP protocol. It connects to AKShare to fetch market data and lets you interact with Claude Desktop for streamlined data queries and insights.
You interact with the AKShare MCP Server through an MCP client. Start the server locally, then connect your MCP client (such as Claude Desktop) to the server using the provided configuration. Once connected, you can perform stock, fund, bond, futures, forex, and macroeconomic data queries, along with other supported data analyses. The server exposes a set of tools you can invoke from your client, each returning structured results suitable for analysis and visualization.
Prerequisites: Python and a supported shell on your system. You will need a Python virtual environment and the uv runtime tool for running the MCP server.
Step 1: Clone the project repository and move into the project directory.
# Clone the project
git clone https://github.com/yourusername/akshare_mcp_server.git
cd akshare_mcp_server
# Create and activate a virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activateStep 2: Install dependencies using uvx (recommended) or pip.
# Install dependencies with uvx (recommended)
uv pip install -e .
# Or install dependencies with pip
pip install -e .Step 3: Run the server locally.
# Activate the virtual environment if not already active
source venv/bin/activate # On Windows: venv\Scripts\activate
# Run the server
python run_server.pyConfigure Claude Desktop to connect to the AKShare MCP Server using the stdio MCP command shown below. This sets the server as akshare-mcp and points Claude Desktop to the directory where the server resides.
"mcpServers": {
"akshare-mcp": {
"command": "uv",
"args": [
"--directory",
"/path/to/akshare_mcp_server",
"run",
"akshare-mcp"
],
"env": {
"AKSHARE_API_KEY": "<your_api_key_if_needed>"
}
}
}Query stock data such as prices, volumes, and other indicators.
Access fund data including fund Net Asset Values, holdings, and performance.
Retrieve bond data such as yields, maturities, and credit information.
Fetch futures contract data, quotes, and analytics.
Obtain foreign exchange rates and cross-rates.
Get macroeconomic indicators and data series.
Support for additional data queries and analysis as the server expands.