Bybit Futures wire format
This page shows how Bybit derivatives, linear contracts (USDT and USDC perpetuals and futures) messages become rows in our Parquet files. For each data type below, you see a real message next to the rows that we publish for it. The page also gives the source and the rule for each column. Put the pointer on a line or a column to see how they connect.
Checked against our pipeline
We recorded these messages from Bybit derivatives, linear contracts (USDT and USDC perpetuals and futures) on 2026-10-05. Our test suite replays each message through the production collector parser and the postprocessor. The test fails if the published rows are different from the rows on this page. Files that we wrote before a change to the pipeline can be different. Refer to Known Gaps & Corrections.
The collector subscribes to orderbook.50.<symbol>, publicTrade.<symbol>, tickers.<symbol> and allLiquidation.<symbol> for each linear contract that is open for trade. The ticker rows, mark price rows and open interest rows all come from the tickers topic.
- Public WebSocket:
wss://stream.bybit.com/v5/public/linear - REST (trade backfill):
https://api.bybit.com
Exchange API reference: bybit-exchange.github.io. For the conventions that apply to all exchanges, refer to the wire formats overview.
Trades
One row for each trade from the publicTrade.<symbol> topic, and for each trade that the collector recovers from REST after a reconnect.
- WebSocket publicTrade.<symbol>
- REST GET /v5/market/recent-trade
Trade message
Bybit sends trades in batches. This message contains 2 trades. Each trade becomes a separate row.
{"topic": "publicTrade.BTCUSDT","type": "snapshot","ts": 1791227620120,→ event_time"data": [{"T": 1791227620119,→ trade_time"s": "BTCUSDT",→ symbol"S": "Buy",→ is_buyer_maker"v": "0.001",→ quantity"p": "85629.30",→ price"L": "PlusTick","i": "caa63c3c-3c80-540f-8364-ea18a6824a70",→ trade_id"BT": false,"RPI": false,"seq": 820927598403},{"T": 1791227620119,→ trade_time"s": "BTCUSDT",→ symbol"S": "Buy",→ is_buyer_maker"v": "0.038",→ quantity"p": "85629.30",→ price"L": "ZeroPlusTick","i": "e629c952-d70a-5354-8ace-495767ec2770",→ trade_id"BT": false,"RPI": false,"seq": 820927598404}]}
Published rows · 2
ts. The time when Bybit made the push. Milliseconds. All trades in the message have the same value.0x1000001b3 instead of the standard FNV prime. Then we clear the sign bit. The same UUID always gives the same ID.true if the taker side S is Sell. false if it is Buy.Market. This is a placeholder because Bybit does not send an order type.REST trade backfill
Bybit does not send old trades again when you subscribe. Each time the trade connection opens or opens again, the collector downloads the latest trades from GET /v5/market/recent-trade. Then it publishes the trades that it did not receive through the WebSocket. If the trade_time of a backfilled trade is not in the hour of the file, we do not publish that trade.
Shortened: We sent this request with limit=1 to keep the example short. The collector sends limit=1000, which is the maximum that Bybit returns.
{"retCode": 0,"retMsg": "OK","result": {"category": "linear","list": [{"execId": "996d7ec5-7333-5567-a813-a4db019fcec2",→ trade_id"symbol": "BTCUSDT",→ symbol"price": "85743.50",→ price"size": "0.002",→ quantity"side": "Buy",→ is_buyer_maker"time": "1791227915662",→ event_time · trade_time"isBlockTrade": false,"isRPITrade": false,"seq": "820929204227"}]},"retExtInfo": {},"time": 1791227915757}
Published row
time. REST responses do not have a push time. Thus, event_time is equal to trade_time on backfilled rows. Milliseconds.0x1000001b3 instead of the standard FNV prime. Then we clear the sign bit. The same UUID always gives the same ID.true if the taker side side is Sell. false if it is Buy.Market. This is a placeholder because Bybit does not send an order type.Notes
- We sort the rows by
trade_time, and then by the Bybit cross sequenceseq. - We do not publish the block-trade flag
BT, the RPI flagRPI, the tick directionLorseq. We publish block trades and RPI trades as normal rows. - If we receive a trade through the WebSocket and also through the REST backfill, we publish it one time, with the WebSocket values. On a backfilled row,
event_timeis equal totrade_time. Thereceived_timecan be some seconds after the trade. - The Bybit REST endpoint returns a maximum of the latest 1,000 trades. Thus, the collector recovers only part of a long reconnect gap on a busy contract.
For the column types and descriptions, refer to the Trades schema.
Order Book
One row for each price level from the orderbook.50.<symbol> topic. We publish each level as Bybit sent it.
- WebSocket orderbook.50.<symbol>
Order book snapshot
Bybit sends a snapshot of the 50-level order book when the subscription starts. It also sends a snapshot after a problem on its side or after a service restart (u = 1). Each level becomes a snapshot row.
Shortened: Bybit sent 50 bid levels and 50 ask levels. The example shows the best three levels of each side.
{"topic": "orderbook.50.BTCUSDT",→ symbol"type": "snapshot",→ event_type"ts": 1791227613628,→ event_time"data": {"s": "BTCUSDT","b": [→ side["85626.10", "6.857"],→ side · price · quantity["85626.00", "0.004"],→ side · price · quantity["85625.90", "0.415"]→ side · price · quantity],"a": [→ side["85626.20", "1.565"],→ side · price · quantity["85626.30", "0.392"],→ side · price · quantity["85626.50", "0.001"]→ side · price · quantity],"u": 211266072,→ final_update_id"seq": 820927562650→ last_update_id},"cts": 1791227613626→ transaction_time}
Published rows · 6
orderbook.50.BTCUSDT). It is equal to data.s.snapshot for type: "snapshot". The message contains all levels of the 50-level order book. A message with u = 1 (Bybit service restart) is also a snapshot.u + 1.seq. It gives the order of the messages, but it does not always increase by 1.bid for levels in b. ask for levels in a. One row for each level.Order book delta
{"topic": "orderbook.50.BTCUSDT",→ symbol"type": "delta",→ event_type"ts": 1791227613708,→ event_time"data": {"s": "BTCUSDT","b": [→ side["85619.20", "0.023"],→ side · price · quantity["85618.80", "0"]→ side · price · quantity],"a": [→ side["85626.20", "1.155"],→ side · price · quantity["85635.70", "0.005"],→ side · price · quantity["85636.20", "0.003"]→ side · price · quantity],"u": 211266074,→ first_update_id · final_update_id"seq": 820927562975→ last_update_id},"cts": 1791227613706→ transaction_time}
Published rows · 5
orderbook.50.BTCUSDT). It is equal to data.s.update for type: "delta".u. Each delta has exactly one update ID. Thus, first_update_id = final_update_id.u of the previous message. A larger step is a gap.seq. It gives the order of the messages, but it does not always increase by 1.bid for levels in b. ask for levels in a. One row for each level.0 removes the level.Notes
- The collector subscribes only to the 50-level order book. WebSocket snapshots are the start point of this order book. The Bybit REST depth snapshots contain the update IDs of the 1,000-level stream. Thus, they cannot be a start point for this order book, and we do not publish them.
- Before the collector writes a delta, it checks that the
uof the delta is one more than theuof the previous message. After a gap, the collector connects again and starts from a new WebSocket snapshot. - We publish a delta with no levels as one row with
side=noop, and withpriceandquantity=0. Thus, the update-ID chain has no holes. Do not use these rows when you rebuild the order book. - A file can start with a checkpoint snapshot of the order book from the previous hour. In this snapshot,
received_timeis the start of the hour andtransaction_timeis null.final_update_idis the lastuthat was applied, andlast_update_idis itsseq. - Quantities are in base asset units (BTC for BTCUSDT). Bybit does not include Retail Price Improvement (RPI) orders in the order book stream.
- Files that we wrote before the October 2026 pipeline update can also contain
snapshotrows from REST depth snapshots. The update IDs of these rows are from the Bybit 1,000-level stream, and they do not continue the 50-level chain. Do not use these rows when you replay the data.
For the column types and descriptions, refer to the Order Book schema.
Ticker
One row for each tickers.<symbol> message that contains a field of the ticker row (lastPrice, prevPrice24h, price24hPcnt, highPrice24h, lowPrice24h, volume24h or turnover24h). Each row contains the full merged state.
- WebSocket tickers.<symbol>
Ticker snapshot
Bybit sends one snapshot with all fields when the subscription starts. This snapshot publishes a ticker row, a mark price row and an open interest row. In our captures, the first snapshot was up to 2 seconds old when we received it. The deltas that Bybit sent after that time came immediately after the snapshot.
{"topic": "tickers.BTCUSDT","type": "snapshot","data": {"symbol": "BTCUSDT",→ symbol"tickDirection": "ZeroPlusTick","price24hPcnt": "0.004251",→ price_change_percent"lastPrice": "85721.40",→ price_change · last_price"prevPrice24h": "85358.50",→ price_change · open_price"highPrice24h": "86986.50",→ high_price"lowPrice24h": "84907.70",→ low_price"prevPrice1h": "85436.60","markPrice": "85730.36","indexPrice": "85768.04","openInterest": "57163.259","openInterestValue": "4900626772.84","turnover24h": "5739447395.0800",→ quote_asset_volume"volume24h": "66763.0850",→ base_asset_volume"fundingIntervalHour": "8","fundingCap": "0.00333","singleOpenInterest": "28581.63","singleOpenInterestValue": "2450313429.29","nextFundingTime": "1791244800000","fundingRate": "0.00001336","bid1Price": "85721.30","bid1Size": "2.542","ask1Price": "85721.40","ask1Size": "10.152","preOpenPrice": "","preQty": "","curPreListingPhase": ""},"cs": 820929695495,"ts": 1791227990283→ event_time}
Published row
lastPrice − prevPrice24h, calculated exactly in decimal.0.004251 becomes 0.4251.prevPrice24h, the price 24 hours ago.Ticker delta
A delta contains only the fields that changed. The row shows the merged state. It contains the changed fields from this delta, and the other fields from earlier messages. We replay this message after the snapshot and the 21 deltas that Bybit sent between them. Those messages prepare the state, and the example does not show their rows.
We replay 22 earlier messages (not shown) before this message. These messages set the start state for this message.
{"topic": "tickers.BTCUSDT","type": "delta","data": {"symbol": "BTCUSDT",→ symbol"tickDirection": "MinusTick","price24hPcnt": "0.00425",→ price_change_percent"lastPrice": "85721.30",→ price_change · last_price"turnover24h": "5739467196.7231",→ quote_asset_volume"volume24h": "66763.3160",→ base_asset_volume"bid1Price": "85721.30","bid1Size": "5.212"},"cs": 820929708680,"ts": 1791227992883→ event_time}
Published row
lastPrice − prevPrice24h, calculated exactly in decimal from the merged state. prevPrice24h is not in this message, so its value comes from earlier messages.0.00425 becomes 0.425.Delta with no ticker field
Most deltas change only the best bid and ask (bid1Price, ask1Price and sizes). We do not publish these fields. If a delta contains no field of a data type, it publishes no row for that data type. This delta publishes no rows. We replay this message after the snapshot and the 17 deltas that Bybit sent between them. Those messages prepare the state, and the example does not show their rows.
We replay 18 earlier messages (not shown) before this message. These messages set the start state for this message.
{"topic": "tickers.BTCUSDT","type": "delta","data": {"symbol": "BTCUSDT","bid1Price": "85721.30","bid1Size": "5.835","ask1Price": "85721.40","ask1Size": "0.744"},"cs": 820929705226,"ts": 1791227992283}
Not published
Notes
- Bybit sends one
snapshotmessage. Then it sendsdeltamessages that contain only the fields that changed. The pipeline merges each message into the full state of the symbol and publishes the merged state. Thus, the values of unchanged fields come from earlier messages. Asnapshotreplaces the state. - The state at the end of an hour continues into the next hour. Sometimes the state of the previous hour is not available (first run, lost state, or an hour without
tickersmessages). Then, until the next snapshot, an hour contains only the fields from its own messages. Files from before the 2026-09 data-integrity release contain rows with only the changed fields, and nulls for unchanged fields. - From the 2026-09 data-integrity release,
price_change_percentis in percent. Earlier files contain the Bybit fraction.
For the column types and descriptions, refer to the Ticker schema.
Mark Price
One row for each tickers.<symbol> message that contains a mark price, index price or funding field. Each row contains the full merged state.
- WebSocket tickers.<symbol>
Ticker snapshot
Bybit sends one snapshot with all fields when the subscription starts. This snapshot publishes a ticker row, a mark price row and an open interest row. In our captures, the first snapshot was up to 2 seconds old when we received it. The deltas that Bybit sent after that time came immediately after the snapshot.
{"topic": "tickers.BTCUSDT","type": "snapshot","data": {"symbol": "BTCUSDT",→ symbol"tickDirection": "ZeroPlusTick","price24hPcnt": "0.004251","lastPrice": "85721.40","prevPrice24h": "85358.50","highPrice24h": "86986.50","lowPrice24h": "84907.70","prevPrice1h": "85436.60","markPrice": "85730.36",→ mark_price"indexPrice": "85768.04",→ index_price"openInterest": "57163.259","openInterestValue": "4900626772.84","turnover24h": "5739447395.0800","volume24h": "66763.0850","fundingIntervalHour": "8","fundingCap": "0.00333","singleOpenInterest": "28581.63","singleOpenInterestValue": "2450313429.29","nextFundingTime": "1791244800000",→ next_funding_time"fundingRate": "0.00001336",→ funding_rate"bid1Price": "85721.30","bid1Size": "2.542","ask1Price": "85721.40","ask1Size": "10.152","preOpenPrice": "","preQty": "","curPreListingPhase": ""},"cs": 820929695495,"ts": 1791227990283→ event_time}
Published row
predictedDeliveryPrice. Bybit documents this field for dated futures. BTCUSDT is a perpetual, and its messages do not contain the field. Thus, the value is null.0.0001 is 0.01 %.Ticker delta with a new index price
Each delta with markPrice, indexPrice, fundingRate, nextFundingTime or predictedDeliveryPrice publishes a mark price row from the merged state. We replay this message after the snapshot and the 16 deltas that Bybit sent between them. Those messages prepare the state, and the example does not show their rows.
We replay 17 earlier messages (not shown) before this message. These messages set the start state for this message.
{"topic": "tickers.BTCUSDT","type": "delta","data": {"symbol": "BTCUSDT",→ symbol"indexPrice": "85768.02",→ index_price"turnover24h": "5739466939.5592","volume24h": "66763.3130","ask1Price": "85721.40","ask1Size": "0.740"},"cs": 820929704683,"ts": 1791227992183→ event_time}
Published row
predictedDeliveryPrice. Bybit documents this field for dated futures. BTCUSDT is a perpetual, and its messages do not contain the field. Thus, the value is null.Notes
- Bybit sends one
snapshotmessage. Then it sendsdeltamessages that contain only the fields that changed. The pipeline merges each message into the full state of the symbol and publishes the merged state. Thus, the values of unchanged fields come from earlier messages. Asnapshotreplaces the state. - The state at the end of an hour continues into the next hour. Sometimes the state of the previous hour is not available (first run, lost state, or an hour without
tickersmessages). Then, until the next snapshot, an hour contains only the fields from its own messages. Files from before the 2026-09 data-integrity release contain rows with only the changed fields, and nulls for unchanged fields. - The Bybit funding interval is different for each contract (
fundingIntervalHour, 8 hours for BTCUSDT here). We do not publish the funding interval or the funding capfundingCap.
For the column types and descriptions, refer to the Mark Price schema.
Open Interest
One row for each tickers.<symbol> message that contains openInterest or openInterestValue. Also, one carried-forward row at the start of each hour.
- WebSocket tickers.<symbol>
Ticker snapshot
Bybit sends one snapshot with all fields when the subscription starts. This snapshot publishes a ticker row, a mark price row and an open interest row. In our captures, the first snapshot was up to 2 seconds old when we received it. The deltas that Bybit sent after that time came immediately after the snapshot.
{"topic": "tickers.BTCUSDT","type": "snapshot","data": {"symbol": "BTCUSDT",→ symbol"tickDirection": "ZeroPlusTick","price24hPcnt": "0.004251","lastPrice": "85721.40","prevPrice24h": "85358.50","highPrice24h": "86986.50","lowPrice24h": "84907.70","prevPrice1h": "85436.60","markPrice": "85730.36","indexPrice": "85768.04","openInterest": "57163.259",→ sum_open_interest"openInterestValue": "4900626772.84",→ sum_open_interest_value"turnover24h": "5739447395.0800","volume24h": "66763.0850","fundingIntervalHour": "8","fundingCap": "0.00333","singleOpenInterest": "28581.63","singleOpenInterestValue": "2450313429.29","nextFundingTime": "1791244800000","fundingRate": "0.00001336","bid1Price": "85721.30","bid1Size": "2.542","ask1Price": "85721.40","ask1Size": "10.152","preOpenPrice": "","preQty": "","curPreListingPhase": ""},"cs": 820929695495,"ts": 1791227990283→ timestamp}
Published row
openInterest. We do not publish the one-sided Bybit value singleOpenInterest.ts. Milliseconds.Ticker delta with a new open interest value
Each delta with openInterest or openInterestValue publishes an open interest row from the merged state. In this message, only the value changed (together with the mark price). Thus, sum_open_interest comes from earlier messages. We replay this message after the snapshot and the 23 deltas that Bybit sent between them. Those messages prepare the state, and the example does not show their rows.
We replay 24 earlier messages (not shown) before this message. These messages set the start state for this message.
{"topic": "tickers.BTCUSDT","type": "delta","data": {"symbol": "BTCUSDT",→ symbol"tickDirection": "ZeroPlusTick","markPrice": "85730.18","openInterestValue": "4900616483.46",→ sum_open_interest_value"turnover24h": "5739473711.5495","volume24h": "66763.3920","ask1Price": "85721.40","ask1Size": "0.668","singleOpenInterestValue": "2450308284.59"},"cs": 820929710650,"ts": 1791227993083→ timestamp}
Published row
ts. Milliseconds.Hour-start carried-forward row
Each hour, each symbol with a known open interest receives a row at the start of the hour. This row contains the state at the hour boundary. The timestamp of this snapshot is just before 20:00 UTC, and we received it just after 20:00 UTC. Thus, it goes into the 20:00 file. It publishes its own row (with the timestamp 19:59), and it is also merged into the hour-start row.
{"topic": "tickers.BTCUSDT","type": "snapshot","data": {"symbol": "BTCUSDT",→ symbol"tickDirection": "PlusTick","price24hPcnt": "0.003552","lastPrice": "85688.40","prevPrice24h": "85385.10","highPrice24h": "86986.50","lowPrice24h": "84907.70","prevPrice1h": "85604.10","markPrice": "85684.30","indexPrice": "85720.48","openInterest": "57257.185",→ sum_open_interest"openInterestValue": "4906041816.70",→ sum_open_interest_value"turnover24h": "5713818688.2134","volume24h": "66461.5850","fundingIntervalHour": "8","fundingCap": "0.00333","singleOpenInterest": "28628.593","singleOpenInterestValue": "2453020951.19","nextFundingTime": "1791244800000","fundingRate": "0.00002009","bid1Price": "85688.40","bid1Size": "5.141","ask1Price": "85688.50","ask1Size": "0.261","preOpenPrice": "","preQty": "","curPreListingPhase": ""},"cs": 820941027667,"ts": 1791230398283→ timestamp}
Published rows · 2
openInterest. We do not publish the one-sided Bybit value singleOpenInterest.ts for the row of the message itself. This time is before the hour. For the carried-forward row, the value is the start of the hour, 1791230400000 (20:00:00 UTC).Notes
- Bybit sends one
snapshotmessage. Then it sendsdeltamessages that contain only the fields that changed. The pipeline merges each message into the full state of the symbol and publishes the merged state. Thus, the values of unchanged fields come from earlier messages. Asnapshotreplaces the state. - The state at the end of an hour continues into the next hour. Sometimes the state of the previous hour is not available (first run, lost state, or an hour without
tickersmessages). Then, until the next snapshot, an hour contains only the fields from its own messages. Files from before the 2026-09 data-integrity release contain rows with only the changed fields, and nulls for unchanged fields. - Bybit documents
openInterestandopenInterestValueas both sides of the market. We do not publish the single-side valuessingleOpenInterestandsingleOpenInterestValue. - In each hour with
tickersmessages, each symbol with a known open interest receives a row at the start of the hour, withtimestamp= the hour start. Itsreceived_timeis the hour start. If a message with a timestamp before the hour arrived after the hour started,received_timeis later (refer to the example). Before the October 2026 pipeline update, this row always hadreceived_time= the hour start, and it did not include such late messages. - We do not publish the output of the REST poller for open interest (
GET /v5/market/open-interest).
For the column types and descriptions, refer to the Open Interest schema.
Liquidations
One row for each entry of an allLiquidation.<symbol> message.
- WebSocket allLiquidation.<symbol>
S is the side of the liquidated position. Sell means that a short position was liquidated. Thus, the published side of the liquidation order is BUY.
{"topic": "allLiquidation.BTCUSDT","type": "snapshot","ts": 1791227636482,→ event_time"data": [{"T": 1791227636066,→ trade_time"s": "BTCUSDT",→ symbol"S": "Sell",→ side"v": "1.312",→ quantity · last_filled_quantity · filled_quantity"p": "85914.10"→ price · average_price}]}
Published row
ts. The time when Bybit made the push. Milliseconds.Buy (a long position was liquidated) becomes SELL. Sell becomes BUY.Market placeholder. Bybit does not send an order type.IOC placeholder. Bybit does not send a time in force.FILLED placeholder. Bybit does not send an order status.v. The same as quantity.v. The same as quantity.Notes
priceandaverage_priceboth contain the bankruptcy price.order_type,time_in_forceandorder_statusare fixed placeholders.filled_quantityandlast_filled_quantityare equal toquantity.datais an array. Each entry becomes a separate row. We sort the rows bytrade_time. Bybit documents a push frequency of 500 ms for this topic. Bybit also states that it pushes all liquidations.
For the column types and descriptions, refer to the Liquidations schema.