MCP MetaTrader 4 Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| MT4_HOST | No | IP address of Windows machine running MT4 | 192.168.50.161 |
| MT4_PORT | No | Port number for HTTP bridge | 8080 |
| MT4_REPORTS_PATH | No | Directory path for EA report files | /tmp/mt4_reports |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| get_account_infoB | Get MetaTrader 4 account information |
| get_market_dataC | Get current market data for a symbol |
| place_orderC | Place a trading order in MetaTrader 4 |
| get_positionsB | Get all open positions |
| close_positionC | Close an open position |
| get_historyD | Get trading history |
| run_backtestC | Run a backtest on an Expert Advisor |
| get_backtest_resultsC | Get results from the last backtest |
| list_expertsB | List available Expert Advisors for backtesting |
| get_backtest_statusB | Get the current status of a running backtest |
| sync_eaC | Upload EA file to MetaTrader 4 for compilation |
| compile_eaC | Compile an EA on MetaTrader 4 and get compilation results |
| list_local_easC | List EAs in the local development folders |
| sync_ea_from_fileC | Sync an existing EA file to MetaTrader 4 |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/8nite/metatrader-4-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server