IBKR
Interactive Brokers MCP Server for Claude Desktop/Code
What is IBKR?
IBKR is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to interactive brokers mcp server for claude desktop/code
Interactive Brokers MCP Server for Claude Desktop/Code
This server falls under the Finance & Fintech category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Interactive Brokers MCP Server for Claude Desktop/Code
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx ibkrConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use IBKR
The IBKR MCP Server connects Claude Desktop and Claude Code to your Interactive Brokers account, exposing portfolio and trading capabilities through natural language. Built with Python and FastAPI, it runs a local REST server that bridges the MCP protocol to the IBKR API so you can query positions, account data, and market information directly from your AI assistant without switching between tools.
Prerequisites
- Python 3.9 or higher installed on your system
- An active Interactive Brokers account with API access enabled
- IBKR TWS (Trader Workstation) or IB Gateway running locally
- An MCP-compatible client such as Claude Desktop or Claude Code
- Git to clone the repository
Clone the repository
Clone the IBKR MCP Server repository from GitHub to your local machine.
git clone https://github.com/seriallazer/ibkr-mcp-server.git
cd ibkr-mcp-serverCreate and activate a virtual environment
Isolate the Python dependencies in a virtual environment to avoid conflicts with other projects.
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activateInstall dependencies
Install all required Python packages listed in requirements.txt.
pip install -r requirements.txtConfigure IBKR credentials
Create a .env file in the project root with your Interactive Brokers API credentials. Ensure IB TWS or IB Gateway is running and has API connections enabled on the default port (7497 for TWS paper, 7496 for TWS live).
cp .env.example .env
# Edit .env and add your IBKR API credentialsStart the MCP server
Launch the FastAPI-based server with uvicorn. It will be available at http://localhost:8000 and expose the API docs at /docs.
uvicorn app.main:app --reloadConfigure Claude Desktop
Add the server to your Claude Desktop configuration file so the MCP client can connect to the running server.
IBKR Examples
Client configuration
Add this to your claude_desktop_config.json to connect Claude Desktop to the running IBKR MCP server. The server must already be running locally via uvicorn.
{
"mcpServers": {
"ibkr": {
"command": "python",
"args": ["-m", "uvicorn", "app.main:app"],
"cwd": "/path/to/ibkr-mcp-server",
"env": {
"VIRTUAL_ENV": "/path/to/ibkr-mcp-server/venv"
}
}
}
}Prompts to try
Once connected, use these prompts in Claude to interact with your Interactive Brokers account.
- "Show me my current portfolio positions and their market values"
- "What is my account balance and available margin?"
- "List my open orders and their statuses"
- "What are my recent trades from the past week?"Troubleshooting IBKR
Server fails to connect to Interactive Brokers
Ensure IB TWS or IB Gateway is running and that API connections are enabled in the settings (Edit > Global Configuration > API > Settings). Check that the port in your .env matches the TWS API port (7497 for paper trading, 7496 for live).
Import errors or missing modules when starting the server
Ensure you have activated the virtual environment before running uvicorn. Run `source venv/bin/activate` (Linux/macOS) or `venv\Scripts\activate` (Windows), then retry.
Claude Desktop cannot reach the MCP server
Verify the uvicorn server is running by visiting http://localhost:8000/docs in your browser. Make sure the cwd and virtual environment paths in your config match your actual installation directory.
Frequently Asked Questions about IBKR
What is IBKR?
IBKR is a Model Context Protocol (MCP) server that interactive brokers mcp server for claude desktop/code It connects AI assistants to external tools and data sources through a standardized interface.
How do I install IBKR?
Follow the installation instructions on the IBKR GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with IBKR?
IBKR works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is IBKR free to use?
Yes, IBKR is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
IBKR Alternatives — Similar Finance & Fintech Servers
Looking for alternatives to IBKR? Here are other popular finance & fintech servers you can use with Claude, Cursor, and VS Code.
ValueCell
★ 10.7kValueCell is a community-driven, multi-agent platform for financial applications.
Vibe Trading
★ 8.1k'Vibe-Trading: Your Personal Trading Agent'
Quantdinger
★ 6.2kAI quantitative trading platform for crypto, stocks, and forex with backtesting, live trading, market data, and multi-agent research.vibe-trading ,trading-agents,ai-trader,ai-trading
TradingView
★ 2.8kReal-time crypto & stock screening, advanced technical indicators, Bollinger Bands intelligence, candlestick patterns + native Claude Desktop integration. Multi-exchange (Binance, KuCoin, Bybit+). Open-source AI trading infrastructure.
Financial Datasets
★ 2.1kProvides access to comprehensive financial data including income statements, balance sheets, cash flow statements, stock prices, company news, SEC filings, and cryptocurrency information with built-in financial ratio analysis.
Stripe
★ 1.6kThe Stripe Model Context Protocol server allows you to integrate with Stripe APIs through function calling. This protocol supports various tools to interact with different Stripe services.
Browse More Finance & Fintech MCP Servers
Explore all finance & fintech servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up IBKR in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use IBKR?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.