CCXT Cryptocurrency Exchange MCP server

Integrates with major cryptocurrency exchanges via CCXT to provide real-time and historical market data for analysis, trading, and portfolio tracking.
Back to servers
Setup instructions
Provider
Nayshins
Release date
Dec 25, 2024
Language
Python
Stats
52 stars

This MCP server provides real-time and historical cryptocurrency market data through integration with major exchanges like Binance, Coinbase, and Kraken. It enables Claude and other LLMs to fetch current prices, analyze market trends, and access detailed trading information across multiple exchanges.

Installation

Installing via Smithery

To install the Cryptocurrency Market Data Server for Claude Desktop automatically via Smithery:

npx -y @smithery/cli install mcp-server-ccxt --client claude

Installing Manually

# Using uv (recommended)
uv pip install mcp ccxt

# Using pip
pip install mcp ccxt

Usage

Running the Server

Start the cryptocurrency market data server with:

python crypto_server.py

Connecting with Claude Desktop

  1. Open your Claude Desktop configuration at:

    • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
    • Windows: %APPDATA%\Claude\claude_desktop_config.json
  2. Add the server configuration:

{
    "mcpServers": {
        "crypto": {
            "command": "python",
            "args": ["/path/to/crypto_server.py"]
        }
    }
}
  1. Restart Claude Desktop

Available Tools

get-price

Get current price for any trading pair

  • Example: "What's the current price of BTC/USDT on Binance?"

get-market-summary

Fetch detailed market information

  • Example: "Show me a market summary for ETH/USDT"

get-top-volumes

List top trading pairs by volume

  • Example: "What are the top 5 trading pairs on Kraken?"

list-exchanges

Show all supported exchanges

  • Example: "Which exchanges are supported?"

get-historical-ohlcv

Get historical candlestick data

  • Example: "Show me the last 7 days of BTC/USDT price data in 1-hour intervals"

get-price-change

Calculate price changes over different timeframes

  • Example: "What's the 24-hour price change for SOL/USDT?"

get-volume-history

Track trading volume over time

  • Example: "Show me the trading volume history for ETH/USDT over the last week"

Example Queries

Here are some example questions you can ask Claude once the server is connected:

  • What's the current Bitcoin price on Binance?
  • Show me the top 5 trading pairs by volume on Coinbase
  • How has ETH/USDT performed over the last 24 hours?
  • Give me a detailed market summary for SOL/USDT on Kraken
  • What's the trading volume history for BNB/USDT over the last week?

Troubleshooting

Common Issues

  1. Exchange Connection Errors

    • Check your internet connection
    • Verify the exchange is operational
    • Ensure the trading pair exists on the selected exchange
  2. Rate Limiting

    • Implement delays between requests
    • Use different exchanges for high-frequency queries
    • Check exchange-specific rate limits
  3. Data Formatting Issues

    • Verify trading pair format (e.g., BTC/USDT, not BTCUSDT)
    • Check timeframe specifications
    • Ensure numerical parameters are within valid ranges

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "crypto" '{"command":"python","args":["/path/to/crypto_server.py"]}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "crypto": {
            "command": "python",
            "args": [
                "/path/to/crypto_server.py"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "crypto": {
            "command": "python",
            "args": [
                "/path/to/crypto_server.py"
            ]
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later