Skip to main content
binXbase

Learn the machinery

8 lessons on how a market physically works, in 4 tracks that build on each other: the book, the orders that touch it, what a fill actually costs, the contracts stacked on top, and the sizing discipline that outlives all of them.

Every lesson ends on a live screen. The prices, books and tapes here are real venue feeds; the balances are paper. That combination is the only reason this material can be practised rather than just read — being wrong costs nothing, and the market you are wrong about is the actual one.

Education, not recommendations — nothing on this site is investment advice.

The path

  1. Foundations3 lessons
  2. Mechanics3 lessons
  3. Derivatives1 lessons
  4. Risk1 lessons
Lessons
8
Glossary terms
46
The whole syllabus
about 126 minutes of reading, counted from the articles themselves rather than estimated

The reading path

The order is not editorial. Each track uses the vocabulary the one above it established, and each lesson names the ones it assumes you have read — so if a paragraph stops making sense, the fix is usually one rung back rather than three paragraphs forward.

Foundations

3 lessons

What a market is physically made of: two lists of orders, the two instructions that touch them, and the chart that summarises the result. Assumes nothing.

  1. How an order book works

    17 min read

    Bids, asks, the spread and depth — the data structure every price on this site comes out of.

    You can
    Read a live ladder from the middle outward and say what a given size would cost before you send it.
    Ends at
    the BTC/USDT order book
  2. Limit vs market orders

    16 min read

    One guarantees a price, the other guarantees a fill. Slippage is what happens when you forget which.

    Assumes
    How an order book works
    You can
    Choose between price certainty and execution certainty for a given size, and know which one you just chose.
    Ends at
    the spot order ticket
  3. Reading candlesticks

    16 min read

    What a candle actually records — open, high, low, close — and what its body and wicks can and cannot tell you.

    Assumes
    How an order book works
    You can
    Say exactly what a candle recorded, and what it does not claim about what happens next.
    Ends at
    the price chart

Mechanics

3 lessons

What happens between pressing a button and owning a fill — the walk through the book, the arithmetic of what it cost, and what an order does while it waits.

  1. How a fill is priced

    13 min read

    Your order walking the live book level by level: the plan, the volume-weighted average, the remainder, and why an unfilled order has no price at all.

    Assumes
    How an order book works · Limit vs market orders
    You can
    Predict the average price and the leftover quantity of an order before you place it, and read a fill list back to check.
    Ends at
    the Fills tab
  2. What a trade really costs

    14 min read

    Fee, spread and slippage are three separate charges on the same order. Add them up and you have the move the market owes you before you are even.

    Assumes
    How a fill is priced
    You can
    Compute the round-trip cost of a position and the break-even move it demands, in the fee this exchange actually charges.
    Ends at
    the convert quote
  3. Orders that wait

    12 min read

    Resting limits, stop triggers and attached exits — what an order does in the hours between placement and fill, and what it has already reserved while it does it.

    Assumes
    Limit vs market orders · How a fill is priced
    You can
    Place an exit before you need it, and know exactly which price event fires it and what it locked when you placed it.
    Ends at
    the terminal’s order tabs

Derivatives

1 lesson

Contracts that never expire, the payment that keeps them tethered to spot, and the price at which the engine takes the position away from you.

  1. Perpetuals and funding

    20 min read

    Futures that never expire, and the funding payments that keep their price tied to spot.

    Assumes
    Limit vs market orders · What a trade really costs
    You can
    Hold a leveraged position knowing which of the three quoted prices decides each thing that can cost you money.
    Ends at
    the BTCUSDT perpetual

Risk

1 lesson

The one input you fully control on every trade. Read last, applied first — it is the only track that changes what you do on all of the others.

  1. Position sizing and risk

    18 min read

    Percent-of-balance thinking: why the size of a loss matters more than the count of wins.

    Assumes
    What a trade really costs · Perpetuals and funding
    You can
    Derive a position size from a written-down exit and a fixed fraction of your balance, rather than from how confident you feel.
    Ends at
    the futures ticket

Every lesson is a legend for this screen

This is the spot terminal, and each pin is a control one of the lessons exists to explain. Keep a lesson in one tab and the terminal in the other; almost everything below becomes obvious the first time you watch it happen to a real book.

The BTC/USDT spot terminal: candlestick chart on the left, order book and trade tape in the middle column, and the order ticket on the right.
  1. 1

    The interval switcher

    Same trades, different buckets. The rightmost candle is still forming — its close is only the latest print, and its high and low can keep extending until the interval ends.

    Reading candlesticks
  2. 2

    The order book, twenty levels a side

    Asks above, bids below, the spread strip between them. The shaded bar behind each row is the cumulative amount between that price and the middle.

    How an order book works
  3. 3

    Limit / Market / Stop-limit

    The three instructions this ticket can send. One guarantees a price, one guarantees a fill, and one is a limit order that does not exist yet.

    Limit vs market orders
  4. 4

    The trade tape

    What actually happened, newest first, coloured by which side crossed the spread. A fill of your own arrives here as a print like any other.

    How a fill is priced
  5. 5

    Order value and Minimum

    What the order is worth before fees, and the smallest one this market will accept. The fee, the spread and the slippage are three more charges on top of it.

    What a trade really costs
  6. 6

    Open orders, Order history, Trade history

    Where an order lives between placement and fill, and the record of every one that finished. A resting limit and an untriggered stop appear here with different statuses.

    Orders that wait

A capture of this product, not a mock-up — but a capture, so every price inside the frame is a moment that has passed rather than a current quote. The live screen is one click away. The perpetuals and position-sizing lessons land on the futures terminal instead, which carries an instrument bar, a leverage slider and a liquidation estimate this screen has no use for.

Glossary

Every term the lessons use, defined twice: once as it is true of any exchange, and then — where this product implements it — as this code actually behaves, with the file that does it. Where we do something a real venue does not, or skip something a real venue does, the entry says so rather than flattering us.

46 terms, grouped

The bookThe structure every price on this site comes out of, and the words for reading it.
Order book

Two sorted lists of orders nobody has traded with yet: bids from the highest price down, asks from the lowest price up. Almost everything a market does falls out of the shape of those two lists.

On this exchange

The book you see is the venue’s own, not ours — Binance’s partial-depth stream, twenty levels a side, a new frame roughly every 100ms. This exchange keeps no book of its own, which is why a fill here is priced against the real one.

Read the lessoncore/exchange/binance-stream.ts
Bid

A resting offer to buy: a price someone will pay and the quantity they will pay it for. You sell into a bid.

Askalso: offer

A resting offer to sell: a price someone will accept and the quantity available at it. You buy from an ask.

Top of bookalso: best bid, best ask, BBO

The highest bid and the lowest ask — the two prices facing each other across the spread. The best bid is always below the best ask, because anything else would already have traded.

Spread

The gap between the best bid and the best ask. It is the price of immediacy: buy and sell in the same breath and you are down the spread before the market has moved.

On this exchange

The terminal renders the spread only when both sides of the book exist. A spread computed against a missing side is a zero that looks like a number.

Level

One price in the book, and everything resting at it. A level is an aggregate — it can be one order or fifty, and the book throws the count away.

Depthalso: liquidity

How much can be bought or sold before the price is somewhere else — the quantity at each level added up as you move away from the spread. Depth answers the question the spread cannot.

On this exchange

The Depth view on the terminal draws the same twenty levels as a cumulative curve. Coarser price grouping buckets those levels into fewer rows; it never fetches more book.

Queue positionalso: price-time priority

Your place among the other orders resting at your price. On almost every venue orders are filled better price first, and among equal prices, earliest first.

On this exchange

This engine does not model it. A resting order here fills when the venue’s book reaches its price, with nobody ahead of it — more generous than a real venue, and worth knowing which way the error runs.

Read the lessonengine/resting.ts
Trade tapealso: time and sales, prints

Every execution as it happens, newest first. The book is what might trade; the tape is what did. A cancelled order leaves no trace on either.

On this exchange

Tape rows are coloured by aggressor side — the incoming order that crossed the spread, not the resting one it hit.

Read the lessoncore/exchange/binance-stream.ts
Aggressoralso: taker side

The side of a trade that crossed the spread to make it happen. The other side was resting and was hit.

On this exchange

The venue reports this as `isBuyerMaker`, which is inverted from the aggressor: buyer-is-maker means the *seller* aggressed. Getting that mapping backwards colours the entire tape the wrong way, so it has a test with captured frames behind it.

core/exchange/binance-stream.ts
The chartHow a tape of real trades becomes candles, and what the compression throws away.
Candlealso: candlestick, bar

One interval of trading compressed to four prices — the first, the highest, the lowest and the last — drawn as a body between open and close with wicks out to the extremes. It is not a summary of the trades; it is the trades, with everything except those four numbers deleted.

On this exchange

The forming 1m bar on our charts is folded from the venue’s trade tape one print at a time, because the futures venue acknowledges its candle stream and then never sends it. A candle is the open, extremes and close of the trades inside its window, so folding the same prints the venue would fold produces the same bar.

Read the lessonmarketd/bars.ts
OHLCalso: open, high, low, close

The four numbers a candle keeps: the open is the interval’s first traded price, the high and low are the extremes it touched, and the close is simply whichever price happened to be last before the clock rolled over. All four really traded — none is an average.

On this exchange

The fold assigns them directly: a print that opens a new bucket sets all four to its own price, and every later print can raise the high, lower the low, and always moves the close.

Read the lessonmarketd/bars.ts
Body

The thick part of a candle, spanning open to close — where the interval settled its business. Its colour records one comparison and nothing else: close above open or close below it. A green candle inside a week-long decline is still green; it is not a verdict.

Wickalso: shadow

The thin line from the body to the highest or lowest price touched inside the interval. A price on a wick really traded — but when inside the interval, how often, and on the way to what are exactly the information the candle no longer contains.

Intervalalso: timeframe, bucket

The bucket size the tape is folded by — one candle per interval. Changing it does not change the market, only the grouping: the same trades at 1m and at 1d draw different pictures, and both are correct.

On this exchange

The chart offers eight, 1m to 1w. Each is fetched from the venue’s own candle endpoint — up to 500 bars — at the moment you select it, and the live-folded bar is applied on 1m only, because painting a 1m bar onto a coarser chart would draw a candle that does not exist.

Volume

The total size traded inside one interval, drawn under the candles. It is the one thing on the chart that is not a price, and it has no direction of its own — every unit of it had both a buyer and a seller.

On this exchange

The forming 1m bar accumulates volume print by print in the same fold that builds its prices; closed bars carry the venue’s own totals. The tint a volume bar wears is its candle’s direction, not a property of the volume.

Read the lessonmarketd/bars.ts
OrdersThe instructions you can send, and the states an order passes through.
Limit order

An order with a price ceiling (buy) or floor (sell). It fills at your price or better, or it waits. It guarantees the price and not the fill.

On this exchange

A limit order that does not cross on placement rests, and its funds are locked at placement rather than at fill.

Read the lessonengine/lifecycle.ts
Market order

An order with a quantity and no price. It crosses the spread and consumes resting orders outward from the best price until the quantity is done. It guarantees the fill and not the price.

On this exchange

Market orders never rest. An unfilled remainder expires rather than joining a book — the same thing the venue does with an order reported EXPIRED against a non-zero executed quantity.

Read the lessonengine/lifecycle.ts
Stop-limit orderalso: stop, trigger price

A limit order that does not exist yet. It waits for the market to reach a trigger price, and only then becomes an ordinary resting limit order.

On this exchange

The trigger is compared against the venue’s last trade print, never the book — a quote can flicker or be withdrawn without anyone trading, and a stop guards against the market actually moving. An exact touch triggers, in both directions.

Read the lessonengine/stops.ts
Time in forcealso: GTC, IOC, FOK

How long an order may live. GTC rests until it fills or is cancelled; IOC fills whatever is immediately available and cancels the rest; FOK fills completely at once or not at all.

On this exchange

Only a GTC limit order rests. Everything else settles or expires in the same breath as it is placed.

Read the lessonengine/lifecycle.ts
Partial fill

Part of an order trades and the rest does not, because the book ran out of counterparties at an acceptable price. Nothing went wrong; it is the normal outcome for a size larger than the depth in front of it.

On this exchange

A match plan carries the leftover quantity explicitly. A resting limit keeps it and waits; a market order lets it expire.

Read the lessonengine/matching.ts
Reduce-only

An order that may only shrink an existing position, never open or extend one.

On this exchange

Reduce-only orders reserve nothing — the position they close is their funding — and they are exempt from the minimum notional, because a position must always be closable whatever it is worth.

Read the lessonengine/futures.ts
Tick size, lot size, minimum notionalalso: precision, min notional

The venue’s rules for a market: the price increment, the quantity increment, and the smallest order value it will accept.

On this exchange

One validator enforces all three, and both the ticket and the engine call it. Two copies of these rules would drift, and the day they did the form would say yes to an order the engine then rejected.

core/orders.ts
Cost and arithmeticWhat a fill is worth, what it charged you, and how the numbers are rounded.
Notional

The value of an order or a position in the quote asset: price × quantity. On a leveraged position it is the whole exposure, not the collateral behind it.

On this exchange

Fees and funding are both charged on notional, which is why a leveraged position’s costs are much larger than its margin suggests.

Read the lessoncore/money.ts
VWAPalso: volume-weighted average price, average fill

The average price of a set of fills, weighted by the size of each. It is what you actually paid, as opposed to the price you saw quoted.

On this exchange

An order that filled nothing has no average price, so this returns null rather than 0. A zero would render as a real-looking price a user could act on.

Read the lessoncore/money.ts
Slippage

The difference between the price you saw and the average you got. It is arithmetic, not misfortune: it appears exactly when your size is larger than the level in front of it.

On this exchange

Orders here fill by walking the venue’s live book level by level, so slippage is real rather than modelled. An engine that filled everything at the top of book would be teaching a lie.

Read the lessonengine/matching.ts
Maker and taker

The resting order makes liquidity; the incoming order takes it. Real venues charge takers more, and sometimes pay makers, because resting orders are what a book is made of.

On this exchange

Every fill on this site is a taker fill and pays the taker rate — there is no local book to rest in, so there is no maker side to reward. There is no maker rebate and no fee tier.

Read the lessonengine/matching.ts
Taker fee

What the venue charges for consuming liquidity, usually quoted in basis points of the order’s value.

On this exchange

Charged in the asset you receive — base on a buy, quote on a sell — so a buy never has to reserve more quote than the order costs. Always rounded up: a fee rounded down is the house paying the remainder on every trade.

Read the lessonengine/fees.ts
Basis pointalso: bps

One hundredth of a percent. 10 bps is 0.10%; 5 bps is 0.05%.

On this exchange

Fee rates live in the code as integer basis points and every percentage on the fees page is derived from them, so a rate change cannot leave a stale number behind in prose.

Rounding direction

Which way a number goes when it will not fit the allowed precision. On money it is never cosmetic.

On this exchange

Quantities round down and fees round up, always, and the rounding function refuses to guess — the caller states the direction. Rounding a quantity up spends money the account does not have; rounding a fee down means the house eats the remainder.

Read the lessoncore/money.ts
DerivativesPerpetual contracts, the collateral behind them and the prices that decide their fate.
Perpetual futurealso: perp

A futures contract with no expiry. Nothing ever settles, you never take delivery, and a position can be held indefinitely — which removes the mechanism that normally keeps a contract tied to spot.

Funding rate

The recurring payment between longs and shorts that replaces expiry as the tether to spot. Positive means the contract is trading above the index and longs pay shorts; negative flips it.

On this exchange

Taken straight from the venue’s premium-index endpoint rather than computed here, and settled every eight hours at 00:00, 08:00 and 16:00 UTC. Your counterparty is an internal ledger account, because there is no crowd here to net against.

Read the lessonengine/funding.ts
Funding payment

What one settlement actually costs: the rate × the position size × the mark price.

On this exchange

Charged on the whole notional, not on the margin behind it, and taken from the futures wallet’s free balance first. With nothing free, it comes out of the position’s own margin — which moves the liquidation price closer to the market.

Read the lessoncore/futures.ts
Mark price

A valuation price anchored to spot rather than to the last print on the futures tape. It exists so that one large order into a thin book cannot decide anyone’s liquidation.

On this exchange

The venue’s premium index. It prices unrealised PnL, the funding payment and liquidation — every decision that can cost you money. The big number on the terminal is the last trade; the mark is in the instrument bar beside it.

Index price

A composite of spot prices across venues, published by the venue. It is the reference the contract’s premium is measured against.

On this exchange

Displayed, and nothing on this site keys off it directly — it is the number that says whether the tether is holding.

Leverage

The ratio between a position’s notional and the collateral posted for it. It multiplies gains, losses, fees and funding alike.

On this exchange

An integer, chosen on the ticket and fixed when the position opens. While a position or a resting entry exists on that contract the slider locks and says why.

Read the lessoncore/futures.ts
Initial margin

The collateral required to open a position: its notional divided by the leverage.

On this exchange

Rounded up. Rounding margin down would let a position exist on slightly less collateral than its leverage claims, and the shortfall would belong to the house.

Read the lessoncore/futures.ts
Maintenance margin

The minimum equity a position may hold before the venue closes it. Reaching it is what liquidation means.

On this exchange

A flat rate of the position’s value at the mark. Real venues widen it in brackets as a position grows; this engine has no tiers yet, and the flat rate is the number every figure on this site uses.

Read the lessoncore/futures.ts
Liquidation price

The mark price at which a position’s equity falls to maintenance margin and the position is closed for you, with a fee attached.

On this exchange

Derived from the position’s own numbers every time it is shown, never stored — a stored copy could disagree with the row it summarises. It is not a stop-loss: a stop is yours, a liquidation is the exchange protecting itself at the worst possible moment.

Read the lessoncore/futures.ts
Isolated margin

Margin posted per position rather than shared across the account. The collateral behind a position is all that position can lose.

On this exchange

The only margin mode here. A disaster on one contract cannot reach into another, and a loss can never exceed the margin posted.

Unrealised PnL

What a position would gain or lose if it closed right now. It is a valuation, not money that has moved.

On this exchange

Priced at the mark and deliberately left unrounded — it becomes a ledger amount only when a reduce or a liquidation settles it, and that path rounds with an explicit direction.

core/futures.ts
Balances and the ledgerWhere value sits between trades, and the accounting that keeps it balanced.
Base and quote asset

In BTC/USDT, BTC is the base — the thing being priced — and USDT is the quote, the thing it is priced in. A buy spends quote and receives base.

Available and locked balancealso: reservation

Available is what you can spend now; locked is what an open order has already claimed.

On this exchange

A resting order reserves its funds at placement, not at fill. That is why placing a limit order lowers your available balance immediately, and why cancelling it returns the money in the same transaction.

engine/reserve.ts
Double-entry ledger

An accounting system in which every movement is written twice, as a debit and a matching credit, so the books can be proved to balance rather than assumed to.

On this exchange

Every fill, fee, transfer, funding charge and liquidation is a balanced set of legs, checked before any of it is written. The counterparty is an external contra account, because this exchange holds no inventory of its own.

engine/settlement.ts
Decimal string

A number stored as text rather than as a floating-point value, so that arithmetic on it is exact.

On this exchange

Anything a user could be owed is one of these, end to end: Postgres stores numeric, the wire carries strings, and one module does every operation. 0.1 + 0.2 ≠ 0.3 is a curiosity in a chart and a defect in a ledger.

core/money.ts
Paper moneyalso: simulated balance

A balance that behaves exactly like money inside a system that custodies nothing outside it.

On this exchange

Every balance on this site. It can come from a simulated deposit, trade, reward or admin adjustment; it moves through a real ledger and pays real fees against real market prices. If withdrawals are enabled, any eligible spot balance can be reviewed and paid from the shared treasury — but only as a valueless test-network token, never cash or a real asset.

Reading is half of it

The other half is watching a live book breathe. Open the terminal, put a lesson in the next tab, and check each idea against the real thing — with balances that cost nothing to be wrong with, on a market that does not care that they are paper.