MT5 Web API

MetaTrader 5 Web API Integration

The MT5 Web API is the foundation of the FXUP platform. Our Go backend integrates directly with MetaTrader 5 to power branded WebTraders, CRM systems, and mobile trading apps for forex brokers worldwide.

What is the MT5 Web API?

The MetaTrader 5 Web API is a RESTful and WebSocket-based interface provided by MetaQuotes that allows external applications to communicate with the MT5 trading server. It enables programmatic access to account management, trade execution, market data, and reporting — all over standard web protocols.

Unlike the older Manager API or Gateway API, the Web API is designed for modern web and mobile applications. At FXUP, we have built our entire platform architecture around this API, using Go as the backend language and Flutter as the frontend framework to create a complete brokerage technology stack.

This means every trade, every account update, and every price tick flows through the Web API — processed by our Go backend and delivered to clients through the WebTrader, CRM, and mobile apps.

  • RESTful endpoints for account and order management
  • WebSocket connections for real-time market data
  • Secure authentication with token-based access
  • Full trade lifecycle management (open, modify, close)
  • Historical data retrieval for charts and reporting
  • Account balance and margin calculations
  • Symbol configuration and trading group access
  • Server-time synchronization for accurate timestamps

Integration Capabilities

What you can build with the MT5 Web API through the FXUP platform.

Account Management

Create, modify, and manage MT5 trading accounts programmatically. Set leverage, assign trading groups, configure margin settings, and manage account permissions. Our CRM uses these endpoints to automate client onboarding — when a client registers and passes KYC, their MT5 account is created automatically.

Trade Execution

Submit market and pending orders, modify existing orders, and close positions through the API. Support for all MT5 order types including market, limit, stop, stop-limit, and close-by orders. The Go backend handles order routing with sub-millisecond processing times for minimal execution delay.

Market Data Streaming

Real-time bid/ask price streaming for all configured instruments via WebSocket connections. Tick-by-tick data delivery to the Flutter frontend for live charts, quotes panels, and depth of market displays. Historical OHLC data retrieval for charting across all available timeframes.

Reporting & Analytics

Pull detailed trade history, balance operations, and performance metrics directly from the MT5 server. Generate reports on trading volume, client activity, profit/loss, and commission accruals. This data powers the CRM's reporting dashboards and client-facing trade history views.

Our Technology Stack

Purpose-built for high-performance MT5 Web API integration.

Go

Backend Language

Go was chosen for the FXUP backend because of its exceptional concurrency model, low memory footprint, and predictable latency characteristics. Goroutines handle thousands of simultaneous WebSocket connections efficiently, while Go's static typing and compiled nature ensure reliability in production. The Go server manages all communication with the MT5 Web API, implements business logic, and serves data to the frontend.

Flutter

Frontend Framework

Flutter provides a single codebase for web, iOS, and Android platforms. Our WebTrader and mobile apps share the same Flutter codebase, ensuring consistent behavior and reducing maintenance overhead. Flutter's rendering engine delivers smooth 60fps animations for charts, real-time price updates, and responsive layouts across all screen sizes.

WebSocket

Real-Time Protocol

WebSocket connections between the Flutter frontend and Go backend provide persistent, bidirectional communication channels. Market data, order updates, and account changes are pushed to clients in real time without polling. The Go server manages connection lifecycle, heartbeat monitoring, and automatic reconnection handling.

Use Cases

How brokers use the MT5 Web API integration through FXUP.

White Label Brokerage

Launch a fully branded brokerage with MT5 white label. The Web API powers all trading operations, client management, and data delivery across your WebTrader, CRM, and mobile platforms.

Grey Label Setup

Start with a grey label on shared infrastructure. The same Web API integration provides identical trading functionality at a lower cost point, with the option to upgrade to a dedicated environment later.

Custom CRM Integration

Connect your brokerage CRM to MT5 for automated account provisioning, real-time balance updates, trade history retrieval, and commission calculations. The Web API is the bridge between your back-office operations and the trading engine.

Branded Trading Apps

Build custom web and mobile trading applications that connect to MT5 via Web API. Our Flutter-based apps provide a modern alternative to the standard MetaTrader terminals, fully branded for your business.

Payment Automation

Automate deposit and withdrawal processing by connecting payment gateways to MT5 through the Web API. When a payment is confirmed, the Go backend credits the MT5 account balance instantly — no manual intervention required.

Risk Monitoring

Monitor client positions, exposure, and margin levels in real time through the Web API. Build custom risk dashboards, set automated alerts for margin thresholds, and track aggregate exposure across trading groups.

Frequently Asked Questions

Do I need my own developers to use the MT5 Web API?+
No. FXUP handles all the technical integration. Our Go backend is already built and optimized for MT5 Web API communication. You receive a turnkey platform — WebTrader, CRM, and mobile apps — without writing any code. If you have your own development team and want custom integrations, we can provide API access and documentation to support your requirements.
How reliable is the MT5 Web API connection?+
The MT5 Web API is a production-grade interface provided by MetaQuotes. Our Go backend adds multiple layers of reliability including connection pooling, automatic reconnection, health monitoring, and failover handling. We maintain persistent connections to the MT5 server with heartbeat monitoring, ensuring trades are processed even during network fluctuations.
What latency can I expect for trade execution?+
The Go backend processes orders in sub-millisecond time before forwarding them to the MT5 server via the Web API. Total execution time depends on market conditions and liquidity provider response, but the FXUP infrastructure adds minimal overhead — typically under 5 milliseconds for the complete round trip from the Flutter client through Go to MT5 and back.
Can the Web API handle high trading volumes?+
Yes. Go's concurrency model is specifically designed for high-throughput applications. Our backend can handle thousands of concurrent WebSocket connections and process hundreds of orders per second. The architecture scales horizontally — as your client base grows, we add capacity without changing the application code.

Build on the MT5 Web API with FXUP

Get a complete trading platform powered by MetaTrader 5 Web API integration. Contact us to discuss your project.

Talk to Our Team