Skip to main content
On the Aries API, paper trading needs no second key and no second base URL. The token you already have lists your live and simulation accounts side by side, and the account ID in each order decides which one trades. That’s convenient, but one wrong account ID means a live order. So the Python file below won’t send anything until it has found a simulation account.

How Do You Place a Paper Trade in Python?

You need an Aries account, a personal-token client (a client ID that starts with ARI-PERSONAL-TK.) from the API tab in Client Center, and Python 3. There’s nothing to install. The API and its market data are free with the account, and stock and options brokerage comes from RAM Financial LLC (DBA Aries), member FINRA and SIPC. The Client Credentials guide explains how the token works. Save this as paper_trade.py:
paper_trade.py
Export your client ID and secret, then run it:
Here’s what it printed for us:
We ran it on Nov 30, 2026, at 3:09 PM ET, with Python 3.15.2, against Aries’ staging server (ARIES_BASE=https://api.tradearies.dev). With your own account, leave ARIES_BASE unset and the file calls https://api.aries.com. The account ID above is made up, and F and 1 share are an example, not a recommendation. Three parts of the file do the work:
  • simulation_account() asks GET /v2/users/me/accounts for every account the token can see and returns only an open one whose is_sim is true. Set ARIES_ACCOUNT_ID to pin one account, and it returns that account only if it’s a simulation account. When we pinned a live account’s ID, it stopped with ... is not an open simulation account. Nothing was sent. It stops the same way when it finds no simulation account at all.
  • order() sends a market order with POST /v1/orders. The reply comes back with status PENDING_NEW, so the function reads GET /v2/accounts/{id}/orders once a second until that order shows FILLED.
  • The User-Agent header. The API turns away Python’s default User-Agent with a 403, so the file sends its own.

What Did the Simulation Fill At?

Price ladder for F from 12.27 to 12.30. The ask is 12.29 and the market buy filled there. The bid is 12.28 and the market sell filled there. Round trip: minus 1 cent, the spread between the bid and the ask.Price ladder for F from 12.27 to 12.30. The ask is 12.29 and the market buy filled there. The bid is 12.28 and the market sell filled there. Round trip: minus 1 cent, the spread between the bid and the ask.

Our run on Aries' staging server, Nov 30, 2026. The quote was read just before the buy.

The buy filled at the ask and the sell at the bid, so even on paper the round trip cost the 1-cent spread. Test the orders that don’t fill, too. With F near 12.29, we sent a limit buy at 10.00:
It sat in the orders list as NEW. We canceled it with POST /v1/orders/cancel, sending the order’s clOrdId as origClOrdId with the same symbol and side, and got back "status": "CANCELED". The order then dropped off the active list.

How Do Other Brokers Set Up Paper Trading?

Here’s how paper trading works at Aries and four other brokers with trading APIs: Tradier also gives each account a paper sandbox. On Aries you keep one set of credentials and one base URL, test on the same market data you’d trade on, and let the guard in simulation_account() keep the two accounts apart. If you’re coming from Alpaca, Switching From Alpaca maps its paper setup and order fields to the Aries API.

How Do You Move From Paper to Live?

Keep the file and the token. The guard refuses live accounts on purpose, so going live is a change you make on purpose too: for example, a separate LIVE_ACCOUNT_ID setting that the code checks has is_sim set to false. Never let a live account become the fallback when no simulation account turns up. Before you switch, preview every order first. The trading bot guide shows POST /v1/orders/preview in a full bot. Once you’re live, follow fills on the account updates WebSocket rather than treating a sent order as filled.