Platform API
cTrader Open API
Spotware's open API for cTrader accounts, JSON or Protobuf over TCP or WebSocket.
Risk warning: CFDs and spread bets are complex instruments and come with a high risk of losing money rapidly due to leverage. You can lose money on these products, and each provider publishes its own loss figure under FCA rules. You should consider whether you understand how they work and whether you can afford to take the high risk of losing your money. Automated and API trading can amplify losses through bugs, connectivity failures and runaway orders.
cTrader API rate limits and allowances
| Limit | Value | Scope | Source |
|---|---|---|---|
| Requests a second, not historical data | 50 | Per connection, requests that are not for historical data | help.ctrader.comchecked |
| Requests a second, historical data | 5 | Per connection, historical data requests only | help.ctrader.comchecked |
Access, authentication and streaming
API types listed in the record: Protobuf over TCP/WebSocket, JSON over TCP/WebSocket, Python package, C# package.
- How you get access
Register an app at openapi.ctrader.com; Spotware reviews new apps, so describe your use case in detail.
Creating a new applicationchecked
- Who can use it
Supported by all trading accounts of any cTrader affiliated brokers by default, which means both demo and live accounts.
cTrader Open APIchecked
- Demo
Yes: separate demo endpoint; demo and live environments are fully separated.
Proxies and endpointschecked
- Authentication
OAuth 2.0 authorisation code flow: the auth code lives 1 minute, the access token 30 days. Scopes are accounts, which is read only, and trading, which is full.
Account authenticationchecked
- Streaming
Yes: spot quotes, depth of market and execution events on the same connection, at 50 requests a second per connection (5 for historical data) with a heartbeat every 10 seconds. Host live1.p.ctrader.com port 5035, SSL mandatory for TCP and WebSocket. Spotware recommends at most two connections, one demo and one live, each carrying an unlimited number of accounts of that type.
Messageschecked
- History depth
Trend bars and ticks by from/to timestamp with optional count; deals by range with maxRows. Cash flow history max 1 week per request.
- Rate limits, as worded
50 requests a second per connection for requests that are not for historical data, and 5 requests a second per connection for historical data requests, as stated on the cTrader Open API documentation home page, re-read 12 Oct 2026.
cTrader API SDKs and wrappers
| Library | Language | Official | Note | Source |
|---|---|---|---|---|
| OpenApiPy (ctrader-open-api) | Python | Official | Official Spotware Python SDK, installed as ctrader-open-api. Latest stable 0.9.2 of 26 Jun 2024; 0.9.3 was released on 6 Aug 2024 and has since been yanked, on a date PyPI does not publish. Asynchronous, built on Twisted plus Protobuf, Python 3.8 to 3.12. No stable release in over two years, though the repository is unarchived with open issues and pull requests. | pypi.orgchecked |
| OpenAPI.Net | C# | Official | Not recorded | Unverifiedgithub.com |
| cTrader MCP server | MCP | Official | Official Spotware MCP server for cTrader, free while in beta. | ctrader.comchecked |
| cTrader Remote and Local MCP servers | Any MCP client | Official | Two official servers launched on 14 May 2026. Remote is driven from cTrader Web with per-account tokens; Local attaches to the desktop app and also controls charts, indicators, plugins, workspaces, UI layout and price alerts. When trading is enabled an agent can place, modify and close real orders, and the confirmation requirement is an MCP server setting rather than a broker-enforced step. | ctrader.comchecked |
| spotware/ctrader-skills (Agent Skills) | Agent Skills | Official | Spotware's official Agent Skills repository: two skills, ctrader-cli and ctrader-mcp-servers, the latter with five helper scripts for pip maths and position sizing. Works with any agent supporting the Agent Skills specification, including Claude Code, Cursor, Windsurf, Codex, Cline and OpenCode, plus a native Claude Code plugin. The licence is proprietary under the Spotware EULA, not open source, which matters if you plan to redistribute. | github.comchecked |
cTrader messages
49 documented messages. They are messages sent over an open connection, not HTTP endpoints: none has a method or a path. Grouped by what they do, each with its summary
cTrader Open API
- ProtoHeartbeatEvent
- ProtoOAAccountAuthReq
- ProtoOAAccountAuthRes
- ProtoOAAccountDisconnectEvent
- ProtoOAAccountLogoutReq
- ProtoOAAccountLogoutRes
- ProtoOAAccountsTokenInvalidatedEvent
- ProtoOAAmendOrderReq
- ProtoOAAmendPositionSLTPReq
- ProtoOAApplicationAuthReq
- ProtoOAApplicationAuthRes
- ProtoOACancelOrderReq
- ProtoOAClientDisconnectEvent
- ProtoOAClosePositionReq
- ProtoOADealListReq
- ProtoOADealListRes
- ProtoOAErrorRes
- ProtoOAExecutionEvent
- ProtoOAExpectedMarginReq
- ProtoOAExpectedMarginRes
- ProtoOAGetAccountListByAccessTokenReq
- ProtoOAGetAccountListByAccessTokenRes
- ProtoOAGetTickDataReq
- ProtoOAGetTickDataRes
- ProtoOAGetTrendbarsReq
- ProtoOAGetTrendbarsRes
- ProtoOANewOrderReq
- ProtoOAOrderErrorEvent
- ProtoOAOrderListReq
- ProtoOAOrderListRes
- ProtoOAReconcileReq
- ProtoOAReconcileRes
- ProtoOARefreshTokenReq
- ProtoOARefreshTokenRes
- ProtoOASpotEvent
- ProtoOASubscribeLiveTrendbarReq
- ProtoOASubscribeLiveTrendbarRes
- ProtoOASubscribeSpotsReq
- ProtoOASubscribeSpotsRes
- ProtoOASymbolByIdReq
- ProtoOASymbolByIdRes
- ProtoOASymbolsListReq
- ProtoOASymbolsListRes
- ProtoOATraderReq
- ProtoOATraderRes
- ProtoOAUnsubscribeSpotsReq
- ProtoOAUnsubscribeSpotsRes
- ProtoOAVersionReq
- ProtoOAVersionRes
cTrader API error codes
53 decoded error codes. All cTrader Open API errors
1The access token has expired.1A generic error.2The trading account has not been authorised on this connection.2The message type is not supported.3Input values are wrong.5Execution timed out.6The id does not exist.7Connection to the server is lost.8Message is too large.9Market is closed.10The order is busy, for example still being executed, so the change was not applied.11Blocked or rate limited.12The trading account no longer exists.14Account already authorised on this connection.35The from and to period is too long or invalid.64The trading account is disabled.67Your app has too many open connections.68The request would increase the risk on a position that has a guaranteed stop loss, which is not allowed.69Trading is disabled for the symbol because of a holiday in its schedule.101App credentials wrong or app not activated.102Command sent before app authorisation.103App authorised twice.104Access token invalid.105The trading service is unavailable.106ctidTraderAccountId not found.107The client ID is not recognised.108Request rate limit exceeded (page gives the name with no longer description).109The server is in maintenance.110Operations are blocked for this account.112A subscription to depth, trendbars or similar was requested for a symbol that has no spot subscription.113You asked for a subscription that is already active.114The symbol does not exist for this account.115The file gives this code no description of its own, only a note that it is to be merged with SYMBOL_NOT_FOUND (114).117Trading cannot be done because no quotes are available.118Insufficient margin.119The maximum exposure for this trader, symbol and side is reached.120Position id does not exist.121The order does not exist.122A request tried to close a position that is not open.123The position is in a state that does not allow the operation to be performed.124The account has hit its limit of open positions and orders.125Volume invalid (cTrader volume is in cents of units).126Stop price invalid.127The price is invalid.128The stake volume is invalid, for example negative.129Stop loss or take profit is invalid or too close to the market.130The expiration given for the order is invalid.131The change cannot be applied because the position has an order under execution.132Symbol not tradable.133The account is read only for your app.134The order could not be cancelled.135The order could not be amended.136Short selling is not allowed for this symbol or account.
cTrader API: questions and answers
Each answer is read from the record on this page, not written separately. Where the record is unverified, the answer says so.
How do I get access to the cTrader API?
Register an app at openapi.ctrader.com; Spotware reviews new apps, so describe your use case in detail.
Creating a new applicationchecked
Who can use the cTrader API?
Supported by all trading accounts of any cTrader affiliated brokers by default, which means both demo and live accounts.
cTrader Open APIchecked
cTrader API demo: is there a demo or sandbox?
Yes: separate demo endpoint; demo and live environments are fully separated.
Proxies and endpointschecked
What are the cTrader API rate limits?
Requests a second, not historical data: 50 requests per second. Scope: Per connection, requests that are not for historical data. Requests a second, historical data: 5 requests per second. Scope: Per connection, historical data requests only. As the record words it: 50 requests a second per connection for requests that are not for historical data, and 5 requests a second per connection for historical data requests, as stated on the cTrader Open API documentation home page, re-read 12 Oct 2026.
help.ctrader.comchecked
How does cTrader API authentication work?
OAuth 2.0 authorisation code flow: the auth code lives 1 minute, the access token 30 days. Scopes are accounts, which is read only, and trading, which is full.
Account authenticationchecked
Does the cTrader API support streaming?
Yes: spot quotes, depth of market and execution events on the same connection, at 50 requests a second per connection (5 for historical data) with a heartbeat every 10 seconds. Host live1.p.ctrader.com port 5035, SSL mandatory for TCP and WebSocket.
Messageschecked
How much history does the cTrader API return?
Trend bars and ticks by from/to timestamp with optional count; deals by range with maxRows. Cash flow history max 1 week per request.
Is there a Python library for the cTrader API?
This register lists one Python library for the cTrader API. OpenApiPy (ctrader-open-api) (official, Python): Official Spotware Python SDK, installed as ctrader-open-api. Latest stable 0.9.2 of 26 Jun 2024; 0.9.3 was released on 6 Aug 2024 and has since been yanked, on a date PyPI does not publish. Asynchronous, built on Twisted plus Protobuf, Python 3.8 to 3.12. No stable release in over two years, though the repository is unarchived with open issues and pull requests.
OpenApiPy (ctrader-open-api)checked
Which brokers offer cTrader?
Unverified. Recorded as offering it but unverified: FxPro and Pepperstone. No broker record carries a verified source for this platform.
Unverifiedno source opened
cTrader API questions, each answered in a sentence or two.
Everything this site records for cTrader Open API, as one JSON file. Each section of the file states its own licence. About the files. This page as Markdown.
cTrader API guides and reference
- cTrader API quickstart: key to first call
- cTrader API error codes
- cTrader Open API with PythoncTrader's API is not REST. It is Protobuf messages over a persistent socket, which is why a Python script that works against IG or OANDA will not translate. This is what changes.
- cTrader API error: application does not contain provided URI
cTrader API compared
The same fields from two records, side by side. No winner is picked.
What changed recently for the cTrader API
Documentation
Re-read today. The token lifetimes are now recorded precisely: authorisation code 1 minute, access token 30 days, with accounts as the read only scope and trading as the full one. The rate limits are unchanged at 50 a second per connection and 5 a second for historical calls.
Change
cTrader AI Agent Connect, launched 14 May 2026, is two official MCP servers plus a skills library. An agent can execute trades, analyse accounts and control charts. Remote MCP serves the web platform and Local MCP the desktop. The server defaults to demo accounts and requires user confirmation before an order action. Execution authority on this site: agent executes.
Ecosystem
Spotware launched official cTrader MCP servers, remote for cTrader Web and local for cTrader Windows.
Spotware newsdate last opened not recorded
The newest entries are shown. Every dated change, all brokers and platforms. Follow cTrader changes by RSS
Sample apps that use the cTrader API
- cTrader OAuth to first orderRuns the cTrader Open API OAuth 2.0 flow against the demo environment, then places one small market order on a demo account.
Open source repositories for cTrader
Read from GitHub's own records and ordered by stars as read. A listing is not a recommendation.
Partner programme
Not verified. No programme page was opened, which is not evidence that no programme exists. The Spotware (cTrader) partner programme record. The programme register holds every record. This site carries no affiliate links.
Brokers that offer cTrader Open API
| Broker | Entity | Note | Source |
|---|---|---|---|
| FxPro | FxPro group (UK entity not confirmed on page) | cTrader listed with C# coding; Open API access not confirmed on the broker's page, and the cTrader FAQ does not confirm availability to FxPro UK Ltd clients. | UnverifiedFxPro platform comparisonchecked |
| Pepperstone | Pepperstone Limited | cTrader platform confirmed; Open API access not confirmed on the broker's page. cTrader Automate (C# bots) is offered to UK clients; spread betting on cTrader not stated. | UnverifiedPepperstone UK cTrader Automatechecked |
How to cite this
cTrader Open API. Broker API Hub, https://openbrokerapi.com/platforms/ctrader, newest check .
Where you rely on a single figure, cite the source and the checked date printed beside it as well.