About CCXT MCP Server
CCXT MCP Server exposes cryptocurrency trading and market data through the CCXT library. It is for MCP clients that need exchange data and order operations, with testnet support and exchanges supported by CCXT.
Key features
- 01Ticker, order book, and recent trade data
- 02Create and cancel orders
- 03Fetch account balances
- 04Trading analysis prompts and order guidance
- 05Testnet support
- 06Cached exchange instances
Use cases
- 01Check prices and market depth for a symbol
- 02Review recent exchange trades
- 03Place or cancel market and limit orders
- 04Test trading workflows on a testnet
MCP support
Provides MCP tools for market data, account balances, and exchange order operations through CCXT. MCP clients can use the server with exchanges supported by CCXT; testnet support is available.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMECCXT MCP Server
A Model Context Protocol (MCP) server that provides trading functionality through the CCXT library.
Features
- Fetch ticker data for any symbol
- Get order book data
- View recent trades
- Create orders (market, limit, etc.)
- Cancel orders
- Fetch account balance
- Trading analysis prompts
- Order management guidance
- Testnet support
- Supports any exchange that CCXT supports
- Cached exchange instances for better performance
Project Structure
src/ccxt_mcp/
├── __init__.py # Main server file
├── utils/
│ └── exchange.py # Exchange management with testnet support
├── tools/
│ ├── fetch_ticker.py # Ticker data tool
│ ├── fetch_order_book.py # Order book tool
│ ├── fetch_trades.py # Trades tool
│ ├── create_order.py # Order creation tool
│ ├── cancel_order.py # Order cancellation tool
│ └── fetch_balance.py # Balance fetching tool
└── prompts/
├── trading_analysis.py # Trading analysis prompt
├── order_management.py # Order management prompt
└── testnet_guidance.py # Testnet guidance prompt
Setup to run MCP server
Prerequisites:
These are instructions for Claude Desktop but this mcp server could be used for any MCP Client.
- Download github repo:
git clone https://github.com/pcriadoperez/ccxt-mcp.git
-
Enter folder
cd ccxt-mcp -
Install mcp server
mcp install run.py -
Open Claude desktop -> Settings -> Developer -> Edit config
- Add your env variables
- You may have Replace in command you uv location (You can find it running
which uv) - It should look like the below config
{
"mcpServers": {
"CCXT Trading Server": {
"command": "/Users/pablo/.local/bin/uv",
"args": [
"run",
"--with",
"ccxt",
"--with",
"mcp[cli]",
"mcp",
"run",
"/Users/pablo/github/ccxt-mcp-2/run.py"
],
"env":{
"BINANCE_APIKEY": "BINANCE_APIKEY",
"BINANCE_SECRET": "BINANCE_SECRET"
}
}
}
}
- Close and open claude
Setup for contributing
- Clone the repository:
git clone https://github.com/pcriadoperez/ccxt-mcp.git
cd ccxt-mcp
- Install dependencies:
uv pip install -e .
- Set up environment variables:
# Copy the example environment file
cp .env.example .env
# Edit .env with your API keys
# Add your exchange API keys in the format:
# {EXCHANGE_ID}_API_KEY=your_api_key
# {EXCHANGE_ID}_SECRET=your_secret
Dev usage
- Run the Dev MCP server:
mcp dev run.py
Security
- Never commit your
.envfile - Use environment variables for API keys
- Consider using a secrets management service for production
- Testnet is recommended for development and testing
Contributing
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
License
MIT
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.