Home › Guides › Grid Trading

BOT TYPE GUIDEFREENO ACCOUNTAUTOMATED TRADE BOTSGrid TradingHow it works and where it breaksEDUCATION ONLY | NO SIGNALSEXAMPLE NUMBERS ARE LABELLEDAUTOMATED TRADE BOTSautomatedtradebots.com
A free page on grid trading. Education only, with example numbers labelled.
BOT TYPE GUIDE

Grid Trading

Short answer

A grid bot places buy orders below the current price and sell orders above it, spaced at fixed steps inside a range. Each completed buy-then-sell pair is one small profit.

Buy orders below, sell orders above, a small profit on each round trip. Here is the arithmetic of a grid and what happens when price walks out of the range.

The page explains how this kind of bot works, works through the arithmetic of its ladder or grid with tables, shows where it breaks, and gives you a fair way to test one before you risk money.

  • How the bot works, step by step
  • The arithmetic of the ladder or grid
  • Where it breaks and how to test it honestly
  • No advice, no signals, no profit promises

Last reviewed 28 October 2026. Education only, not advice.

Free, no account Runs in your browser Worked numbers shown Not advice Examples labelled

Ready to go further

Run your own grid numbers

Enter a range, a number of grids and a fee and see the profit per grid and the money needed.

Open the grid calculatorFree, no account
Reading time6 minutes
Worked exampleExact arithmetic
Tools linked1 on this page
Reviewed28 Oct 2026

What is included

  • How the bot works, step by step
  • The arithmetic of the ladder or grid, with tables
  • How it fails and how to test it honestly
  • The tools that check the numbers

Who it is for

  • People thinking of using this kind of bot
  • People already running one and wanting a stress test
  • Readers comparing bot types before buying
  • Not advice, and not a recommendation to use one
A made-up price path that stays inside a 90 to 110 grid90100110012345678910Top of range 110Bottom of range 9092108Step (made-up price path, 10 grids completed)Made-up example. Each sell above and each buy below a line is one fill.
The picture for this page. Example numbers are made up unless the page says they were calculated.

Key facts

  • A grid bot places buy orders below the current price and sell orders above it, spaced at fixed steps inside a range. Each completed buy-then-sell pair is one small profit.
  • It earns when price moves back and forth across the lines. It does not need to predict direction.
  • In a made-up grid of 10 grids between 90 and 110, with 5 units per grid, the ten grids together earn 90.00 after a 0.1 percent fee each side (calculated by us on 27 Oct 2026, exact).
  • If price leaves the range at the bottom, the bot is left holding the asset at a loss. If it leaves at the top, everything is sold and the bot sits in cash.
  • Grids use the same idea as martingale and averaging down: exposure builds up as price moves against the bot.

What a grid bot does

A grid bot is given a price range, a number of grids and an amount of money. It draws evenly spaced price lines between the bottom and the top of the range. It puts a buy order at each line below the current price and a sell order at each line above it. When price falls to a buy line, the order fills and the bot places a sell order one line higher. When price rises to that line, the sell fills and the bot has finished one round trip. The profit is the gap between the two lines times the units, less costs.

The bot never predicts anything. It simply sells a little higher than it bought, over and over, as long as price keeps crossing the lines. That is why people describe grids as built for sideways markets. A market that goes up and down inside the range gives the bot many round trips. A market that goes one way gives it very few.

Arithmetic versus geometric spacing

There are two common ways to space the lines. Arithmetic spacing keeps the price gap the same, for example 2 between every line. Geometric spacing keeps the percent gap the same, so the price gap grows as price rises. In this made-up range, arithmetic spacing is 2 on every step, which is 2.22 percent at the bottom and 1.85 percent at the top. Geometric spacing is about 2.03 percent on every step. Which one a bot offers varies by platform.

LineArithmetic priceGapGap %Geometric priceGapGap %
090.00--90.00--
192.002.002.22%91.821.822.03%
294.002.002.17%93.691.862.03%
396.002.002.13%95.581.902.03%
498.002.002.08%97.521.942.03%
5100.002.002.04%99.501.982.03%
6102.002.002.00%101.522.022.03%
7104.002.001.96%103.572.062.03%
8106.002.001.92%105.672.102.03%
9108.002.001.89%107.812.142.03%
10110.002.001.85%110.002.192.03%

Calculated by us on 27 Oct 2026, exact (geometric prices rounded to two places). Percent spacing matters because costs are a percent of the trade. A line gap smaller than the round trip cost earns nothing, as the page on grid bot fees and costs shows.

A worked example, grid by grid

All numbers here are a made-up example. An asset is trading at 100. The range is 90 to 110, split into 10 grids, so there are 11 lines two apart. Each grid trades 5 units. Fees are 0.1 percent of the value on each side. Grid 1 buys at 90 and sells at 92, grid 2 buys at 92 and sells at 94, and so on up to grid 10, which buys at 108 and sells at 110.

GridBuy atSell atUnitsGross profitFeesNet profitNet % of buy cost
190.0092.00510.000.919.092.02%
292.0094.00510.000.939.071.97%
394.0096.00510.000.959.051.93%
496.0098.00510.000.979.031.88%
598.00100.00510.000.999.011.84%
6100.00102.00510.001.018.991.80%
7102.00104.00510.001.038.971.76%
8104.00106.00510.001.058.951.72%
9106.00108.00510.001.078.931.68%
10108.00110.00510.001.098.911.65%

Every completed grid earns between 8.91 and 9.09 after fees, and all ten together earn 90.00. Note the shape: the profit per grid is small and fixed. The money at work is not small. Holding a unit on every buy line costs 4950 in this example, so one cycle of the whole grid earns about 1.82 percent on that money. Calculated by us on 27 Oct 2026, exact.

Same grid, three made-up paths: result in money (fees ignored)+100.00Stays in rangerealised 160.00-600.00Falls to 85held 50 units+150.00Rises to 115all sold, idle cashCalculated by us on 27 Oct 2026, exact. Made-up prices, 5 units per grid, start at 100.
The same grid on three made-up price paths. Realised profit is only a part of the picture: what the bot still holds at the end counts too.

What happens when price leaves the range

A grid only works between its first and last line. Outside that, it has no orders left to fill. To make the example concrete, assume the bot starts at 100: it buys 25 units at the start price to cover the five sell orders above (at 102, 104, 106, 108 and 110) and keeps five buy orders below (at 98, 96, 94, 92 and 90). That needs 4850 of money in total. Fees are ignored in the next table to keep the arithmetic readable.

Made-up pathGrids completedRealised profitUnits held at endUnrealised resultRealised + unrealised
100 down to 92 and back, up to 108 and back, ending 10010160.0025-60.00100.00
100 down to 85 and stays00.0050-600.00-600.00
100 up to 115 and stays5150.0000.00150.00

Leaving at the bottom

When price falls through every buy line the bot has bought all the way down. In this example it holds 50 units. Price 85 is below every buy, so the position shows an unrealised result of -600.00. The loss is only on paper until the units are sold, but the bot has no orders left, and its money is tied up in an asset that is falling. If price recovers into the range, the grid starts working again. If it does not, the bot is simply a long position with a loss.

Leaving at the top

When price rises through every sell line, the bot has sold everything. It earned 150.00 from the five sells, and now holds cash while price keeps rising. It cannot buy back in unless price returns to a buy line. This is not a loss, but it is the cost of being out: a plain holder would have kept gaining. Calculated by us on 27 Oct 2026, exact.

Why it favours sideways markets

Both exits show the same thing. A grid sells into strength and buys into weakness. That helps when price oscillates and hurts when price trends. Each step down in a trend adds one more unit to the pile at a lower price than the last, which is the same behaviour as martingale, only with equal sizes. On leveraged markets the pile can also be liquidated, as futures grid liquidation shows.

Close relatives of the grid

  • DCA bots buy on a schedule or as price falls and sell at a profit target. See the DCA bot page.
  • Martingale ladders add more size at each lower step. See martingale.
  • Zone recovery hedges instead of averaging in one direction. See zone recovery.
  • Trailing or moving grids shift the range as price moves, which avoids leaving it but changes what the bot holds.

Where to go next

Put your own range and counts through the grid calculator. For the choices behind a setup see grid trading strategy, and for the evidence question see are grid bots profitable.

FAQ

Frequently Asked Questions

What is grid trading?

A method that places buy orders at fixed price steps below the market and sell orders at fixed steps above it. Each time price crosses a pair of lines it completes a small buy-then-sell profit.

Does a grid bot need the market to go up?

No. It needs price to move back and forth across its lines. Its worst case is a steady move in one direction, which leaves it holding a falling asset or sitting in cash on a rising one.

What is the difference between arithmetic and geometric grids?

Arithmetic grids keep the price gap the same between lines. Geometric grids keep the percent gap the same. Which choices exist depends on the bot platform.

What happens if price falls below the lowest line?

All buy orders have filled and the bot holds the asset with an unrealised loss. It has no orders left to place until price returns into the range, unless it has a stop or a rule that moves the grid.

How is a grid different from martingale?

A plain grid keeps each order the same size and martingale makes them bigger. Both pile up exposure as price moves against them, so a long trend hurts both.

Are the numbers on this page real?

Example numbers are made up to show how the maths works, and the page says so. A figure only counts as exact when the page says it was calculated on a stated date. Nothing you enter in a calculator leaves your browser.

Can I use this to decide whether to run a bot?

It can show whether a bot's numbers hold together and how much an account can lose. It cannot say what the market will do, and it is not advice. Use it to ask better questions, then read the terms of your own broker or exchange.

Is this financial advice?

No. It is general education about how a type of bot works. All prices on this page are made up, and it does not consider your situation.

Know the Risk Before You Run It

Free calculators and guides, added every week. Leave your details and we will email you when new ones go up.

Trading carries a risk of loss