MetaTrader MCP Server
📑 Table of Contents
- What is This?
- Features
- Who Is This For?
- Important Disclaimer
- Prerequisites
- Quick Start
- Trading Assistant Skill
- Usage Examples
- Available Operations
- WebSocket Quote Server
- Advanced Configuration
- Roadmap
- Development
- Contributing
- Documentation
- Getting Help
- License
🌟 What is This?
MetaTrader MCP Server is a bridge that connects AI assistants (like Claude, ChatGPT) to the MetaTrader 5 trading platform. Instead of clicking buttons, you can simply tell your AI assistant what to do:
"Show me my account balance" "Buy 0.01 lots of EUR/USD" "Close all profitable positions"
The AI understands your request and executes it on MetaTrader 5 automatically.
How It Works
You → AI Assistant → MCP Server → MetaTrader 5 → Your Trades
✨ Features
- 🗣️ Natural Language Trading - Talk to AI in plain English to execute trades
- 🤖 Multi-AI Support - Works with Claude Desktop, ChatGPT (via Open WebUI), and more
- 📊 Full Market Access - Get real-time prices, historical data, and symbol information
- 💼 Complete Account Control - Check balance, equity, margin, and trading statistics
- ⚡ Order Management - Place, modify, and close orders with simple commands
- 🔒 Secure - All credentials stay on your machine
- 🌐 Flexible Interfaces - Use as MCP server, REST API, or WebSocket stream
- 📖 Well Documented - Comprehensive guides and examples
🎯 Who Is This For?
- Traders who want to automate their trading using AI
- Developers building trading bots or analysis tools
- Analysts who need quick access to market data
- Anyone interested in combining AI with financial markets
⚠️ Important Disclaimer
Please read this carefully:
Trading financial instruments involves significant risk of loss. This software is provided as-is, and the developers accept no liability for any trading losses, gains, or consequences of using this software.
By using this software, you acknowledge that:
- You understand the risks of financial trading
- You are responsible for all trades executed through this system
- You will not hold the developers liable for any outcomes
- You are using this software at your own risk
This is not financial advice. Always trade responsibly.
📋 Prerequisites
Before you begin, make sure you have:
- Python 3.10 or higher - Download here
- MetaTrader 5 terminal - Download here
- MT5 Trading Account - Demo or live account credentials
- Login number
- Password
- Server name (e.g., "MetaQuotes-Demo")
🚀 Quick Start
Step 1: Install the Package
Open your terminal or command prompt and run:
pip install metatrader-mcp-server
Step 2: Enable Algorithmic Trading
- Open MetaTrader 5
- Go to
Tools→Options - Click the
Expert Advisorstab - Check the box for
Allow algorithmic trading - Cl
