Core Features
Paper Trading
Practice trading with a $10,000 virtual portfolio. Follow signals automatically, track equity over time, and measure performance with professional metrics — all without risking real capital.
How It Works
Open positions
Manually enter trades or enable auto-follow to mirror every signal.
Track in real-time
Open P&L updates with simulated price ticks. SL/TP triggers automatically.
Measure performance
Win rate, Sharpe ratio, max drawdown, profit factor — all calculated live.
Opening a Position
Use the order form on the /paper-trading page, or call the API directly:
curl -X POST http://localhost:3000/api/paper-trading/open \
-H "Content-Type: application/json" \
-d '{
"symbol": "XAUUSD",
"direction": "BUY",
"size": 0.1,
"stopLoss": 2280.00,
"takeProfit": 2350.00
}'{
"id": "pt_abc123",
"symbol": "XAUUSD",
"direction": "BUY",
"size": 0.1,
"entryPrice": 2315.40,
"stopLoss": 2280.00,
"takeProfit": 2350.00,
"openedAt": "2026-03-27T10:00:00.000Z",
"status": "open",
"unrealizedPnl": 0
}Auto-Follow Signals
Enable auto-follow to automatically open a paper position for every new signal. The system uses the signal's recommended TP/SL levels.
curl -X POST http://localhost:3000/api/paper-trading/follow-signal \
-H "Content-Type: application/json" \
-d '{
"signalId": "XAUUSD-H1-BUY",
"size": 0.1
}'Tip:Use the toggle on the Paper Trading page's signal feed panel to enable auto-follow without writing code.
Closing Positions
Close a single position
curl -X POST http://localhost:3000/api/paper-trading/close \
-H "Content-Type: application/json" \
-d '{ "id": "pt_abc123" }'Close all positions
curl -X POST http://localhost:3000/api/paper-trading/close-allReset portfolio
# Resets balance to $10,000 and clears all history
curl -X POST http://localhost:3000/api/paper-trading/resetPerformance Metrics
The stats endpoint returns professional performance metrics:
curl http://localhost:3000/api/paper-trading/statsWin Rate
Percentage of profitable closed trades
Sharpe Ratio
Risk-adjusted return (annualized)
Max Drawdown
Largest peak-to-trough decline
Profit Factor
Gross profit / gross loss ratio
Total Return
Portfolio gain/loss from $10,000
Avg Win
Average profit on winning trades
Avg Loss
Average loss on losing trades
Open Positions
Currently active trades
Data Storage
Paper trading data is stored in data/paper-trading.json. This includes account balance, open positions, and closed trade history. The file persists across restarts when using Docker volumes or running on disk.
API Reference
/api/paper-trading/api/paper-trading/open/api/paper-trading/close/api/paper-trading/close-all/api/paper-trading/reset/api/paper-trading/follow-signal/api/paper-trading/stats