Getting Started Guide

How to Paper Trade an Algorithm (No Code Required): A Quick Guide

Paper trading an algorithm means running a fixed set of trading rules against live market prices with simulated money, so you can watch an idea behave without any capital at risk. This guide gives you a simple illustrative strategy to test (a moving-average crossover, used only to teach the process), then splits the work into two hands-on paths: Path A, where you follow the rules and record each signal by hand, and Path B, where the strategy runs through a broker or simulator API and submits simulated orders. It includes a completed sample journal, walks through what a real result does and does not prove, and points to where automated execution introduces brand-new failures like duplicate orders and disconnects.

12 min readBeginnerUpdated Jul 26, 2026

Educational purposes only. This content does not constitute investment advice. Read our disclaimer

StockCram is not a broker-dealer, investment adviser, or financial institution. All content is for educational and informational purposes only and should not be construed as personalized investment advice. Consult a qualified financial professional before making investment decisions. Past performance does not guarantee future results.
Share

What You'll Learn

  • The difference between manual forward testing (Path A) and automated paper trading (Path B)
  • A simple, clearly illustrative moving-average crossover strategy to test the process
  • How to keep a paper-trading journal, with a completed sample you can copy
  • How to run the strategy through a simulator or broker API and what new failures that exposes
  • What a paper result actually proves, and how small samples fool you

The Strategy You Will Test

Before anything else, here is the concrete idea you will paper trade in this guide. It is a moving-average crossover, one of the most commonly taught example rules. It is used purely to make the process concrete. It is illustrative, not a recommendation to trade it.

A moving average is the average price over a set number of days, recalculated each day so it slides forward. A crossover rule watches two of them, a shorter one and a longer one:

- Entry: record a simulated buy when the 20-day average closes above the 50-day average.
- Exit: record a simulated sell when the 20-day average closes below the 50-day average.

That is the whole strategy. It is popular in lessons because you can see it directly on a chart: when the fast line pushes above the slow line, that is one signal; when it drops back below, that is the other. A rule you fully understand is one you can actually study, which is why we keep it deliberately plain.

An algorithm, in this context, is simply this kind of clear if-then rule set. It does not require code. "If the fast average crosses above the slow one, buy; if it crosses below, sell" is an algorithm. It is a recipe a computer could follow, written plainly enough that you could follow it yourself. Paper trading is what happens when you run that recipe on live prices with simulated money and watch what it does.

The one-sentence version

An algorithm is a set of if-then trading rules. Paper trading runs those rules on live prices with simulated money, so you can observe the behavior without any capital at risk.

Price line chart with a fast 20-day moving average and a slow 50-day moving average, with buy markers where the fast line crosses above the slow line and sell markers where it crosses below.
The crossover signals: buy where the fast average crosses above the slow average, sell where it crosses below. Illustrative, not a recommendation.

Two Paths: Record by Hand or Let It Run

There are two genuinely different ways to paper trade the strategy above, and they test different things. Knowing which one you are doing keeps you honest about what your result actually means.

Path A: Manual forward testing (no code). You watch the market, apply the rules yourself, and record each signal by hand in a journal as it happens. No programming is involved. This tests the trading logic: does the idea produce signals that behave the way you expected when it meets a live market it has never seen?

Path B: Automated paper trading. The strategy runs through a broker or simulator API and submits simulated orders on its own. This tests the logic plus the execution plumbing: order handling, timing, and operational reliability. It surfaces problems that never appear when a human is clicking, such as the same order firing twice, an order filling only partway, a delay between signal and submission, or the connection dropping mid-run.

Most people start with Path A, confirm the logic makes sense, and only later move to Path B to see whether the mechanics hold up. Neither path involves real money, and neither one proves an idea will make money. They answer different questions, so the rest of this guide walks through each in turn.

Educational comparison of the two paths. Both use simulated money only.
DimensionPath A: Manual forward testPath B: Automated paper trading
Who acts on signalsYou, by handSoftware, via an API
Mainly testsThe trading logicLogic plus execution reliability
Code requiredNoneSome, to connect the strategy
New failures it revealsMostly none beyond your own disciplineDuplicate orders, partial fills, latency, disconnects
Good forUnderstanding the idea firstUnderstanding whether the mechanics hold up

Where Paper Trading Fits Next to Backtesting

People often blur paper trading and backtesting together, but they answer different questions and have different weaknesses. Understanding the split is one of the most useful things a beginner can learn.

Backtesting replays your rules over historical data. You take the last few months or years of price history and ask what these rules would have done back then. It is fast, because you can compress years into seconds, and it lets you see many trades quickly. Its danger is hindsight: it is easy to keep tweaking a rule until it looks great on the exact past you tested it on, which teaches you about that history rather than about the future.

Paper trading runs your rules forward, in real time, on live prices you have never seen. There is no hindsight, because tomorrow has not happened yet. Its cost is patience: you gather new data points at the speed the market actually moves, so building a meaningful number of trades takes real calendar time.

The two complement each other. Backtesting can help you spot obviously broken logic quickly. Paper trading checks whether an idea holds up when it cannot peek at the answer. Neither one proves an idea will make money. The Backtesting lesson in the Algorithmic Trading course goes deeper on the traps of testing on history.

Educational comparison. Hypothetical and illustrative only; past performance does not indicate future results.
DimensionBacktestingPaper Trading
Data usedPast, historical pricesLive, real-time prices
DirectionLooks backwardRuns forward
SpeedFast (years in seconds)Real time (one day per day)
Main riskCurve-fitting to known historySlow to gather enough trades
What it can showHow rules behaved on that historyHow rules behave with no hindsight

Path A: Run the Manual Forward Test

Path A is the place to begin. You follow the crossover rules yourself and record every signal by hand. Here is the process start to finish.

Step 1: Write the rule as explicit entry and exit conditions. Vague ideas cannot be tested. You already have the plain if-then version from the strategy section: buy the simulated position when the 20-day average closes above the 50-day, sell when it closes below. Also write down the boring details in advance: which symbol, how much simulated money per position, and what you will do if a signal is unclear. Deciding these upfront stops you from quietly changing the rules mid-run.

Step 2: Pick a paper-trading simulator. Choose a platform that offers a paper or simulated account with live prices. Several charting and broker platforms include one. (StockCram is not affiliated with, endorsed by, or sponsored by any platform or brokerage.) You want something that starts you with a virtual balance and clearly labels the account as simulated, so you never confuse it with real trading.

Step 3: Log every decision. This is the step people skip, and it is the most important. Keep a simple journal: the date, what the rule said, the price when you acted, and the outcome. Note the trades you took and, just as usefully, the ones you hesitated on. The log is where learning actually happens, because it lets you compare what the rule told you to do with what you did and what followed. The sample below shows exactly what to record.

Step 4: Run it long enough to matter. A handful of trades tells you almost nothing. A rule can win five times in a row and still be a coin flip. Give it enough time and enough signals that the results are not just a short lucky or unlucky streak. In live paper trading, that usually means weeks or months, not an afternoon.

Step 5: Understand what "it worked" really means. If the run looks good, stay skeptical. A small sample can flatter a mediocre rule, and plain luck can carry a stretch of trades. If you quietly adjusted the rule whenever it stumbled, you were curve-fitting to the recent past rather than testing a fixed idea. A good stretch over a short window is a hypothesis to keep examining, never a conclusion.

*Hypothetical and illustrative only; past performance does not indicate future results. The moving-average crossover is used here to teach the process and is not a recommendation.*

The most common self-deception

Changing your rule every time it loses, then judging the improved version on the same data, makes almost any idea look good. That is curve-fitting. Fix the rules before the run, and judge them without editing history.

A Completed Sample Journal

Here is what a filled-in Path A journal looks like after a short run of the crossover strategy. Every row is hypothetical, invented to show the format, and none of it is real trading data. The point is the columns and the discipline, not the numbers.

The two columns that teach the most are Expected fill vs Simulated fill (the gap between them is slippage, even in a simulator) and Rule followed? (an honest record of whether you actually did what your own rules said, or overrode them). A journal is only useful if you record the times you broke your own process, not just the clean trades.

Hypothetical and illustrative only; past performance does not indicate future results. These rows are invented to demonstrate the journal format.
DateSignalRuleExpected fillSimulated fillSlippageResultRule followed?
Mar 3Buy20-day closed above 50-day$100.00$100.12$0.12OpenYes
Mar 19Sell20-day closed below 50-day$104.50$104.31$0.19Closed +$4.19Yes
Apr 2Buy20-day closed above 50-day$103.80$103.95$0.15OpenNo, entered a day late
Apr 15Sell20-day closed below 50-day$101.20$101.05$0.15Closed -$2.90Yes
Apr 30Buy20-day closed above 50-day$102.60$102.74$0.14Skipped (hesitated)No, ignored the signal

Path B: Automated Paper Trading Through an API

Once the logic makes sense by hand, Path B checks whether it survives being run by software. Here the strategy connects to a broker or simulator through an API and submits simulated orders automatically. Nothing here uses real money.

How it connects. Many brokers and simulators expose a paper or sandbox environment through an API: a set of endpoints your program calls to read prices and place simulated orders. Your strategy watches the moving averages, and when the crossover fires, it sends a simulated order to that sandbox instead of you clicking a button. Some no-code and low-code tools can wire this up without heavy programming, but even then you are now depending on a live connection and an order-handling layer.

The new failures this exposes. This is the whole reason to run Path B. Automating execution introduces problems a human clicker never sees:

- Duplicate orders. A retry, a bug, or a missed acknowledgement can send the same order twice, leaving you with double the intended position.
- Partial fills. The simulator may fill only part of an order, so the strategy's assumption that it is fully in or fully out no longer holds.
- Latency. Time passes between the signal, the order being sent, and the fill coming back. During fast moves, the price you act on is not the price you saw.
- Disconnects. If the connection drops, the strategy can miss a signal entirely, or lose track of whether an order went through.

These are operational-reliability problems, not strategy problems. A rule with perfectly sound logic can still behave badly if the plumbing around it is fragile, which is exactly what paper-testing the automation is meant to reveal before any of it touches real stakes. For the operational depth here, see the Paper Trading and Going Live lesson, which covers the sandbox-to-live transition in context.

*Everything in Path B uses a simulated or sandbox environment. Nothing here is a suggestion to connect a strategy to a live account.*

Same rule, different result

Picture the crossover strategy firing a buy. By hand, you enter once at a clean price. Automated, a dropped acknowledgement resends the order and you are in twice, then a partial fill leaves you half out on the exit. Identical logic, very different behavior. Hypothetical and illustrative only.

A four-step progression from Backtest to Manual forward test to Automated paper execution to a Small live account, with a note that most people pause to study at each gate.
A common learning progression. Most people stop and study at each gate rather than rushing forward. Educational only; this is not a prompt to go live.

What Paper Trading Cannot Tell You

A simulator is a helpful teacher, but a lenient one. It tends to give your rules an easier ride than the real market would. Knowing the gaps keeps you from over-trusting a clean paper result, on either path.

Real fills and slippage. In simulation, an order often fills at or near the price you saw. In real markets, the price can move between your decision and your fill, so you get a slightly worse price. That gap is slippage, and it quietly eats into results that looked tidy on paper.

Liquidity and partial fills. A simulator usually assumes you can buy or sell as much as you want at the quoted price. Real markets have limited liquidity: for larger orders or thinner symbols, there may not be enough buyers or sellers at that price, so an order can fill only partway or push the price against you.

Fees and other costs. Depending on what and where you trade, real activity can carry commissions, spreads, or other costs. Many simulators ignore these or model them loosely, so a paper strategy that looks like it breaks even might not once real costs are included.

The psychology of real money. Clicking buy with fake money feels nothing like risking money you actually care about. Fear, greed, hesitation, and the urge to override your own rules show up far more strongly when the loss is real. A rule you followed perfectly on paper can be a very different experience under real pressure.

None of this makes paper trading useless. It makes it a starting point. It teaches the mechanics and behavior of your rules while staying quiet about the frictions and emotions that only appear with real stakes.

Reset without ego

The whole point of a simulator is that resetting costs nothing. If a run goes sideways, treat it as data. The goal is to learn the process, not to protect a fake score.

What People Consider Before Ever Risking Real Money

This section is education, not a nudge. Nothing here is a signal that anyone is ready, and nothing here says you should go live. It simply describes the kinds of questions thoughtful people ask themselves after a long paper-trading phase across both paths.

Did I gather enough evidence? Many people ask whether they have seen enough trades across enough different market conditions, calm and volatile, to say anything at all, or whether they are reacting to a short, lucky stretch.

Did I keep the rules fixed? A common question is whether the rules stayed constant through the run, or whether they were quietly edited whenever results dipped. A result only means something if the idea it tested was not changing underneath it.

Did the automation actually hold up? For anyone who ran Path B, the question is whether the execution layer behaved reliably: no duplicate orders, no silent disconnects, no drift between what the strategy thought it held and what the account showed.

Do I understand the frictions I did not simulate? People often revisit slippage, liquidity, and fees, and ask how much those could erode a result that looked fine on paper.

Have I thought about risk and my own tolerance for loss? Understanding how much a plan could lose, and how that lines up with personal risk tolerance, is a concept people study long before anything real is involved. The Risk Management and Failure Modes lesson covers how trading systems break.

The purpose of listing these is not to say pass them and go live. It is to show that the leap from a simulated result to real risk involves a long list of considerations, and that paper trading answers only a few of them. Whether anyone ever risks real money is a personal decision that depends on individual circumstances and is well beyond the scope of an educational guide.

Related Guides

Continue Your Learning

Related Terms

Key Takeaways

1

Two paths, two different tests

Path A (record signals by hand) tests your trading logic. Path B (run it through a simulator API) tests the logic plus the execution plumbing: order handling, timing, and reliability. Most people start with Path A.

2

Paper trading uses simulated money only

You run fixed rules against live prices with virtual capital. Nothing is at risk, which makes it a low-cost way to observe how an idea behaves before drawing any conclusions.

3

A good idea is not the same as a good outcome

A rule can look successful over a short window purely by luck. Small samples, curve-fitting, and randomness can all make a mediocre idea appear to work.

4

Automation exposes failures manual testing hides

The moment a strategy submits its own orders, you inherit duplicate orders, partial fills, latency, and disconnects. That operational reliability is exactly what Path B is for.

Frequently Asked Questions

Write your strategy as plain if-then rules, such as a moving-average crossover, then open a paper-trading account that uses live prices and simulated money. Whenever your rules trigger, you place the simulated order yourself and record it in a journal. This is Path A, manual forward testing. No programming is required because you are following the rules by hand, and no real money is involved because the balance is virtual.

Manual forward testing (Path A) has you apply the rules and record each signal by hand, which tests whether the trading logic behaves as expected. Automated paper trading (Path B) connects the strategy to a broker or simulator API so it submits simulated orders on its own, which tests the logic plus the execution plumbing. Path B exposes failures manual testing hides, such as duplicate orders, partial fills, latency, and disconnects.

Backtesting runs your rules over past, historical data to see what they would have done, which is fast but prone to hindsight and curve-fitting. Paper trading runs the same rules forward on live prices you have never seen, which removes hindsight but takes real calendar time to gather enough trades. They answer different questions, and neither one proves future profitability.

Yes. That is exactly what a paper-trading simulator is for. It gives you a virtual balance and lets you place simulated orders against real market prices, so you can watch how a set of rules behaves without any capital at risk. Keep in mind it teaches mechanics and behavior, not guaranteed results, and it hides real-world frictions like slippage and fees.

Long enough that the results are not just a short lucky or unlucky streak. A handful of trades tells you almost nothing, because a rule can win several times in a row by chance. In live paper trading that usually means weeks or months and a meaningful number of signals across both calm and volatile conditions. Even then, a good stretch is a hypothesis to keep examining, not proof.

No. A clean paper result is not a signal to risk real money, and this guide does not suggest doing so. Simulators tend to give rules an easier ride than reality, hiding slippage, liquidity limits, fees, and the psychology of real stakes. Whether anyone ever trades with real money is a personal decision that depends on individual circumstances and many considerations well beyond a simulation. Hypothetical and illustrative only; past performance does not indicate future results.

Sources & References

  1. 4 Reasons to Try Paper Trading | Charles Schwab | 2024 | Last verified July 2026 | https://www.schwab.com/learn/story/4-reasons-to-try-paper-trading
  2. Algorithmic Trading: A Beginner's Guide | Interactive Brokers | 2023 | Last verified July 2026 | https://www.interactivebrokers.com/campus/ibkr-quant-news/algorithmic-trading-a-beginners-guide/
  3. Paper Trading Main Functionality | TradingView | 2024 | Last verified July 2026 | https://www.tradingview.com/support/solutions/43000516466-paper-trading-main-functionality/
  4. Paper Trading API Documentation | Alpaca | 2024 | Last verified July 2026 | https://docs.alpaca.markets/docs/paper-trading

Found this guide helpful?

Share