Comprehensive OKX Historical Data

  • Tick-by-tick order book snapshots & updates, trades, funding rates and more
  • Tick-level spot, futures and perpetual swaps datasets
  • over 3 years of high-frequency data history

Trusted by 400+ customers globally. You're in good company.

Comprehensive tick-level datasets

OKX historical tick-by-tick order book snapshots, incremental L2 updates, trades, quotes, tickers, funding rates and liquidations.

1 symbol timestamp local_timestamp is_snapshot side price amount
2 BTC-USD-SWAP 1640995199969000 1640995200006242 false bid 46205 4
3 BTC-USD-SWAP 1640995199985000 1640995200021651 false ask 46224.3 22
4 BTC-USD-SWAP 1640995199985000 1640995200021651 false ask 46228.2 0
5 BTC-USD-SWAP 1640995199985000 1640995200021651 false bid 46208.5 2
6 BTC-USD-SWAP 1640995199985000 1640995200021651 false bid 46203.9 15
7 BTC-USD-SWAP 1640995199985000 1640995200021651 false bid 46184 0
8 BTC-USD-SWAP 1640995199985000 1640995200021651 false bid 46181.8 56
9 BTC-USD-SWAP 1640995199985000 1640995200021651 false bid 43700 0
10 BTC-USD-SWAP 1640995199996000 1640995200032179 false ask 46236.2 0

OKX swap tick-level order book L2 updates collected from exchanges' WebSocket feeds

Download sample See CSV schema
1 symbol timestamp local_timestamp asks[0].price asks[0].amount bids[0].price bids[0].amount asks[1].price asks[1].amount bids[1].price bids[1].amount asks[2].price asks[2].amount bids[2].price bids[2].amount asks[3].price asks[3].amount bids[3].price bids[3].amount asks[4].price asks[4].amount bids[4].price bids[4].amount asks[5].price asks[5].amount bids[5].price bids[5].amount asks[6].price asks[6].amount bids[6].price bids[6].amount asks[7].price asks[7].amount bids[7].price bids[7].amount asks[8].price asks[8].amount bids[8].price bids[8].amount asks[9].price asks[9].amount bids[9].price bids[9].amount asks[10].price asks[10].amount bids[10].price bids[10].amount asks[11].price asks[11].amount bids[11].price bids[11].amount asks[12].price asks[12].amount bids[12].price bids[12].amount asks[13].price asks[13].amount bids[13].price bids[13].amount asks[14].price asks[14].amount bids[14].price bids[14].amount asks[15].price asks[15].amount bids[15].price bids[15].amount asks[16].price asks[16].amount bids[16].price bids[16].amount asks[17].price asks[17].amount bids[17].price bids[17].amount asks[18].price asks[18].amount bids[18].price bids[18].amount asks[19].price asks[19].amount bids[19].price bids[19].amount asks[20].price asks[20].amount bids[20].price bids[20].amount asks[21].price asks[21].amount bids[21].price bids[21].amount asks[22].price asks[22].amount bids[22].price bids[22].amount asks[23].price asks[23].amount bids[23].price bids[23].amount asks[24].price asks[24].amount bids[24].price bids[24].amount
2 BTC-USD-200103 1577836801628000 1577836802068424 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.95 39 7181.21 482 7181.96 100 7180.87 140 7181.97 2 7180.17 1 7182.34 48 7180.16 8 7182.42 2 7180.13 42 7182.47 1 7179.8 1 7182.87 1 7179.18 17 7183.05 2 7179.05 32 7183.32 92 7178.97 48 7183.33 35 7178.76 40 7183.66 2 7178.39 71 7183.68 2 7178.27 4 7183.74 2 7178.2 10 7183.75 2 7177.99 50 7183.98 2 7177.97 2 7184.12 9 7177.94 3 7184.19 2 7177.38 109 7184.35 24 7177.37 10 7184.59 45 7177.35 37 7184.73 4 7177.07 167 7184.85 2 7176.96 3 7184.96 101 7176.93 12 7185.11 32 7176.77 11
3 BTC-USD-200103 1577836801685000 1577836802646524 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.95 39 7181.21 482 7181.96 100 7180.87 140 7181.97 2 7180.17 1 7182.34 48 7180.16 8 7182.42 2 7180.13 42 7182.47 1 7179.8 1 7182.87 1 7179.18 17 7183.05 2 7179.05 32 7183.32 92 7178.97 48 7183.33 35 7178.76 40 7183.66 2 7178.39 71 7183.68 2 7178.27 4 7183.74 2 7178.2 10 7183.75 2 7177.99 50 7183.98 2 7177.97 2 7184.12 9 7177.94 3 7184.19 2 7177.38 109 7184.35 24 7177.37 10 7184.59 45 7177.35 37 7184.73 4 7177.08 111 7184.85 2 7177.07 167 7184.96 101 7176.96 3 7185.11 32 7176.93 12
4 BTC-USD-200103 1577836801707000 1577836802646671 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.96 100 7181.21 482 7181.97 2 7180.87 140 7182.34 48 7180.17 1 7182.42 2 7180.16 8 7182.47 1 7180.13 42 7182.87 1 7179.8 1 7183.05 2 7179.18 17 7183.32 92 7179.05 32 7183.33 35 7178.97 48 7183.66 2 7178.76 40 7183.68 2 7178.39 71 7183.74 2 7178.27 4 7183.75 2 7178.2 10 7183.98 2 7177.99 50 7184.12 9 7177.97 2 7184.19 2 7177.94 3 7184.35 24 7177.37 10 7184.59 45 7177.35 37 7184.73 4 7177.08 111 7184.85 2 7177.07 167 7184.96 101 7176.96 3 7185.11 32 7176.93 12 7185.25 9 7176.77 11
5 BTC-USD-200103 1577836801745000 1577836802651049 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.96 100 7181.21 482 7181.97 2 7180.87 140 7182.34 48 7180.17 1 7182.42 2 7180.16 8 7182.47 1 7180.13 42 7182.87 1 7179.8 1 7183.05 2 7179.18 17 7183.32 92 7179.05 32 7183.33 35 7178.97 48 7183.66 2 7178.76 40 7183.68 2 7178.39 71 7183.74 2 7178.27 4 7183.75 2 7178.2 10 7183.98 2 7177.99 50 7184.12 9 7177.97 2 7184.19 2 7177.94 3 7184.33 4 7177.37 10 7184.35 24 7177.35 37 7184.59 45 7177.08 111 7184.73 4 7177.07 167 7184.85 2 7176.96 3 7184.96 101 7176.93 12 7185.11 32 7176.77 11
6 BTC-USD-200103 1577836801768000 1577836802651184 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.97 2 7181.21 482 7182.34 48 7180.87 140 7182.42 2 7180.17 1 7182.47 1 7180.16 8 7182.87 1 7180.13 42 7183.05 2 7179.8 1 7183.32 92 7179.18 17 7183.33 35 7179.05 32 7183.66 2 7178.97 48 7183.68 2 7178.76 40 7183.74 2 7178.39 71 7183.75 2 7178.27 4 7183.98 2 7178.2 10 7184.12 9 7177.99 50 7184.19 2 7177.97 2 7184.35 24 7177.94 3 7184.59 45 7177.37 10 7184.73 4 7177.35 37 7184.85 2 7177.08 111 7184.96 101 7177.07 167 7185.11 32 7176.96 3 7185.25 9 7176.93 12 7185.45 2 7176.77 11
7 BTC-USD-200103 1577836801842000 1577836802935188 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.97 2 7181.21 482 7182.34 48 7180.87 140 7182.42 2 7180.17 1 7182.47 1 7180.16 8 7182.87 1 7180.13 42 7183.05 2 7179.8 1 7183.32 92 7179.18 17 7183.33 35 7179.05 32 7183.66 2 7178.97 48 7183.68 2 7178.76 40 7183.74 2 7178.39 71 7183.75 2 7178.27 4 7183.98 2 7178.2 10 7184.12 9 7177.99 50 7184.19 2 7177.97 2 7184.35 24 7177.94 3 7184.59 45 7177.37 10 7184.73 4 7177.36 111 7184.85 2 7177.35 37 7184.96 101 7177.08 111 7185.11 32 7177.07 167 7185.25 9 7176.96 3 7185.45 2 7176.93 12
8 BTC-USD-200103 1577836801864000 1577836802935339 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.97 2 7181.21 482 7182.23 40 7180.87 140 7182.34 48 7180.17 1 7182.42 2 7180.16 8 7182.47 1 7180.13 42 7182.87 1 7179.8 1 7183.05 2 7179.18 17 7183.32 92 7179.05 32 7183.33 35 7178.97 48 7183.66 2 7178.76 40 7183.68 2 7178.39 71 7183.74 2 7178.27 4 7183.75 2 7178.2 10 7183.98 2 7177.99 50 7184.12 9 7177.97 2 7184.19 2 7177.94 3 7184.35 24 7177.37 10 7184.59 45 7177.36 111 7184.73 4 7177.35 37 7184.85 2 7177.07 167 7184.96 101 7176.96 3 7185.11 32 7176.93 12 7185.25 9 7176.77 11
9 BTC-USD-200103 1577836802034000 1577836802944517 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.97 2 7181.21 482 7182.23 40 7180.87 140 7182.34 48 7180.17 1 7182.42 2 7180.16 8 7182.47 1 7180.13 42 7182.87 1 7179.8 1 7183.05 2 7179.18 17 7183.32 92 7179.05 32 7183.33 35 7178.97 48 7183.66 2 7178.76 40 7183.68 2 7178.39 71 7183.74 2 7178.27 4 7183.75 2 7178.2 10 7183.98 2 7177.99 50 7184.12 9 7177.97 2 7184.19 2 7177.94 3 7184.35 24 7177.37 10 7184.59 45 7177.36 111 7184.73 4 7177.35 37 7184.85 2 7177.08 112 7184.96 101 7177.07 167 7185.11 32 7176.96 3 7185.25 9 7176.93 12
10 BTC-USD-200103 1577836802046000 1577836802944629 7181.46 9 7181.45 15 7181.82 40 7181.22 92 7181.97 2 7181.21 482 7182.23 40 7180.87 140 7182.34 48 7180.17 1 7182.42 2 7180.16 8 7182.47 1 7180.13 42 7182.87 1 7179.8 1 7183.05 2 7179.18 17 7183.32 92 7179.05 32 7183.33 35 7178.97 48 7183.66 2 7178.76 40 7183.68 2 7178.39 71 7183.74 2 7178.27 4 7183.75 2 7178.2 10 7183.98 2 7177.99 50 7184.12 9 7177.97 2 7184.19 2 7177.94 3 7184.35 24 7177.37 10 7184.59 45 7177.35 37 7184.73 4 7177.08 112 7184.85 2 7177.07 167 7184.96 101 7176.96 3 7185.11 32 7176.93 12 7185.25 9 7176.77 11

OKX futures tick-level order book snapshots reconstructed from WebSocket order book data

Download sample See CSV schema
1 symbol timestamp local_timestamp id side price amount
2 BTC-USDT 1640995201601000 1640995201643834 288060049 buy 46218.3 0.00004153
3 BTC-USDT 1640995201608000 1640995201647576 288060050 sell 46218.2 0.03332021
4 BTC-USDT 1640995201716000 1640995201757137 288060051 sell 46218.2 0.00001428
5 BTC-USDT 1640995202348000 1640995202387618 288060052 buy 46218.3 2.1e-7
6 BTC-USDT 1640995203772000 1640995203810520 288060053 buy 46218.3 0.00004564
7 BTC-USDT 1640995203772000 1640995203811636 288060054 buy 46218.3 0.01756436
8 BTC-USDT 1640995207859000 1640995207897432 288060055 sell 46218.2 0.01354
9 BTC-USDT 1640995207859000 1640995207897433 288060056 sell 46218.2 0.04
10 BTC-USDT 1640995207859000 1640995207897445 288060057 sell 46218.2 0.04211009

OKX spot individual trades data collected from exchanges' WebSocket feeds

Download sample See CSV schema
1 symbol timestamp local_timestamp type strike_price expiration open_interest last_price bid_price bid_amount bid_iv ask_price ask_amount ask_iv mark_price mark_iv underlying_index underlying_price delta gamma vega theta rho
2 BTC-USD-200327-10500-P 1583020800666000 1583020801502613 put 10500 1585296000000000 7 0.2025 0.2115 15 0.3906 0.239 15 0.8594 0.22434823 0.6647 BTC-USD -1.0594421698 2.438221401 0.0006612213 -0.0008187097
3 BTC-USD-200626-5000-P 1583020801283000 1583020801502645 put 5000 1593158400000000 1 0.0105 0.01 305 0.708 0.0115 305 0.7324 0.01011242 0.7096 BTC-USD -0.0611372213 0.321611259 0.0005941415 -0.0001795538
4 BTC-USD-200626-24000-C 1583020801283000 1583020801502662 call 24000 1593158400000000 3 0.015 0.0125 305 0.9717 0.014 305 0.9912 0.01285332 0.9765 BTC-USD 0.0519620905 0.1764952671 0.0007171202 -0.0002982735
5 BTC-USD-200626-13000-P 1583020801283000 1583020801502677 put 13000 1593158400000000 0 0.5035 305 0.7031 0.5175 305 0.7813 0.51124655 0.7468 BTC-USD -1.2631062574 2.0083584728 0.0017891499 -0.0005643564
6 BTC-USD-200626-16000-P 1583020801283000 1583020801502711 put 16000 1593158400000000 0 0.76 15 0.8875 15 1.1792 0.82574343 0.8105 BTC-USD -1.6771052495 2.1785786111 0.0013066005 -0.0004431611
7 BTC-USD-200626-10000-C 1583020801283000 1583020801502724 call 10000 1593158400000000 0 0.1075 305 0.6787 0.1115 305 0.6983 0.109204 0.6869 BTC-USD 0.3486735153 0.6688964214 0.0022470024 -0.0006566778
8 BTC-USD-200626-13000-C 1583020801283000 1583020801502739 call 13000 1593158400000000 30 0.0535 0.0495 305 0.7373 0.0525 305 0.7544 0.05112074 0.7468 BTC-USD 0.1958664828 0.5493857326 0.0017891499 -0.0005688873
9 BTC-USD-200626-24000-P 1583020801283000 1583020801502762 put 24000 1593158400000000 0 1.6055 15 1.8085 15 1.6895 1.70749314 0.9765 BTC-USD -2.6415260452 2.8699834029 0.0007171202 -0.0002815863
10 BTC-USD-200626-30000-P 1583020801283000 1583020801502775 put 30000 1593158400000000 0 2.2485 15 2.506 15 2.0093 2.37822513 1.0912 BTC-USD -3.3281334518 3.491966945 0.0005747103 -0.0002438302

OKX options tick-level options chain data collected from exchanges' WebSocket feeds

Download sample See CSV schema

Real-time consolidated and normalized market data streaming is available via our open source libraries that connect directly to exchanges' WebSocket APIs — it's free, no vendor lock-in, no increased latency due to streaming data through 3rd party API.

Ready to get started? Start your order or read the docs to learn more.