Open-source project
binance/binance-public-data avatar
binance/binance-public-data

binance-public-data documents zipped market files whose SPOT timestamps switched to microseconds in 2025

Details on how to get Binance public data

2,578 stars623 forksPythonLicense varies

At a glance

What is it?
binance-public-data is the documentation and helper-script repository for data.binance.vision, which serves Binance market data as daily and monthly zip files for SPOT, USD-M Futures and COIN-M Futures. It explains the file columns, the download URL pattern and the checksum check.
Who is it for?
Use binance-public-data when you need bulk historical Binance trades or candles for backtesting and would rather download zip files than page through the REST API. Skip it if you need data from the current day, since daily files arrive the next day.
Can I use it commercially?
The repository metadata does not identify a licence. Check the project’s published terms and any component-specific licences before reuse.
Is it still maintained?
Yes. The repository last received commits 41 days ago.
What is it written in?
Mainly Python, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 24, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • binance/binance-public-data2,578 ★ · +18
Star history
Repository2026-11-032026-11-24
binance/binance-public-data2.6k2.6k

18 Stars in the last 21 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

Files are published per day or per month, and daily data lands one day late

The data lives on the website data.binance.vision, and this repository explains it. Binance's public market data is aggregated into daily or monthly files. All symbols are supported. New daily data becomes available the next day, and new monthly data arrives on the first Monday of the month.

That schedule sets the shape of what you can do. You cannot build a live feed from these files, and yesterday's trades are the freshest thing you can get from the daily archive. The month in progress is not in the monthly archive until the following month's first Monday. For recent data inside that window, you have to use the exchange API instead.

Three kinds of files are described for SPOT and, with variations, for futures: aggTrades, klines and trades. The repository holds no data itself. Its top level has README.md, TERMS_AND_CONDITIONS.md, python/, shell/ and updates/, which is documentation, two sets of download scripts and a record of corrections.

SPOT timestamps count microseconds from January 1st 2025 onwards

A note in the README warns that the timestamp for SPOT data from January 1st 2025 onwards is in microseconds. Earlier files use milliseconds. The sample rows show the change: a SPOT kline open time of 1735689600000000 has sixteen digits, while a futures kline row from 2017 shows 1499040000000 with thirteen.

A backtest that joins data across the boundary will break quietly if it assumes one unit. A parser that converts with a fixed divisor will read 2025 SPOT rows as dates far in the future, or fail on overflow in a narrow integer type. Check each file's year before choosing the unit, and treat the futures files separately, since the warning names SPOT only. The sample futures rows in the README still show millisecond-length values.

The same rule reaches the close time column in klines and the time column in trades, since they carry timestamps too.

Each SPOT file mirrors an API endpoint, and the kline columns include an Ignore field

SPOT aggTrades files come from the /api/v3/aggTrades endpoint. The columns are aggregate trade ID, price, quantity, first trade ID, last trade ID, timestamp, whether the buyer was the maker, and whether the trade was the best price match.

Klines files come from /api/v3/klines, with twelve columns: open time, open, high, low, close, volume, close time, quote asset volume, number of trades, taker buy base asset volume, taker buy quote asset volume, and a final column named Ignore. The Ignore field is a leftover from the API response, so drop it when loading.

Trades files come from /api/v3/historicalTrades with trade ID, price, quantity, quote quantity, time, isBuyerMaker and isBestMatch.

The kline intervals available are 1s, 1m, 3m, 5m, 15m, 30m, 1h, 2h, 4h, 6h, 8h, 12h, 1d, 3d, 1w and 1mo. The monthly interval is written 1mo and not 1M so that the names do not collide on case-insensitive file systems. If your code builds file names from the API's interval strings, translate 1M to 1mo.

Futures columns differ between USD-M and COIN-M, so one loader does not fit both

Futures come in two products, USD-M and COIN-M, and the files follow their own endpoints. aggTrades matches /fapi/v1/aggTrades or /dapi/v1/aggTrades, with seven columns and no best-price-match flag. USD-M klines come from /fapi/v1/klines and COIN-M klines from /dapi/v1/klines.

The headers of the two kline tables differ. USD-M uses quote asset volume, while COIN-M uses base asset volume and a taker buy volume column next to taker buy base asset volume. Trades differ as well: USD-M trades files, from /fapi/v1/trades, include quoteQty, and COIN-M trades files, from /dapi/v1/trades, carry baseQty in its place.

A loader that expects the USD-M header will mislabel COIN-M columns, since both have twelve kline columns in a similar order. Key your schema by market, not just by file type. The COIN-M sample row shows prices like 9640.7 with one decimal, so numeric precision also varies between the products.

A download is a plain curl or wget against a predictable path

File URLs follow a pattern on data.binance.vision: market, frequency, data type, symbol, interval and then the file name with the date. The README gives this example for monthly SPOT 1h klines of the ADABKRW symbol:

shell
# Examples for downloading monthly Spot 1h lines for "ADABKRW" symbol.
curl -s "https://data.binance.vision/data/spot/monthly/klines/ADABKRW/1h/ADABKRW-1h-2020-08.zip" -o ADABKRW-1h-2020-08.zip
wget "https://data.binance.vision/data/spot/monthly/klines/ADABKRW/1h/ADABKRW-1h-2020-08.zip"

More examples come as helper scripts in the python/ and shell/ folders. To list every currently running symbol on Spot and Futures, there is shell/fetch-all-trading-pairs.sh.

Because paths are regular, you can generate them in a loop over symbols and months. The cost is volume: every symbol and interval is its own file, so a full pull multiplies quickly. Take the symbol list from the script, then request only the intervals you need.

Every zip has a .CHECKSUM file, and past corrections are listed with their own checksums

Each zip file sits next to a .CHECKSUM file in the same folder, for verifying integrity:

shell
# Linux
sha256sum -c BNBUSDT-1m-2021-01.zip.CHECKSUM

# MacOS
shasum -a 256 -c BNBUSDT-1m-2021-01.zip.CHECKSUM

Archived files can be replaced later when an issue is found. The README lists the updates made to the archive, with file path and the checksums of the replaced and replacement files. Two appear: on 2022-08-08 a kline update fixed inconsistent data, and on 2022-04-21 an aggregate trade update aligned the archive with a Spot aggregate trade data change, linked to an entry in the Binance Spot API docs changelog.

That means a file you downloaded earlier may no longer match the archive. If you cache data, record the checksum next to each file and compare it with the current .CHECKSUM before reusing a dataset from before those dates. The updates/ folder holds the two zip files that describe the replacements.

Terms live in a separate document, and the license field disagrees with the README

How the dataset may be used is governed by TERMS_AND_CONDITIONS.md, which the README points to for details. Read it before redistributing the files or building a product on them, since this article does not summarize its content.

The license information is split. The README ends with the line Licence: MIT, while the repository's license field shows unknown, because the top level has no LICENSE file. The MIT statement most plausibly covers the scripts, and the dataset terms sit in the separate document. Do not read the MIT line as permission to reuse the market data.

The repository has no GitHub releases and was last pushed to on 2026-09-30. It is not archived. Questions and problems go through the repository's issues page. With no releases, track the master branch or the commit you copied scripts from, and watch the updates table for any corrections to files you depend on.

Editorial conclusion

Use binance-public-data when you need bulk historical Binance trades or candles for backtesting and would rather download zip files than page through the REST API. Skip it if you need data from the current day, since daily files arrive the next day. Before loading anything, check the timestamp unit for SPOT files dated 2025 or later, then verify each zip against its .CHECKSUM file.

Frequently asked questions

Is the Binance public data free to download?

The data.binance.vision site offers the files for anyone to download, and the repository lists no fee. Usage terms are in TERMS_AND_CONDITIONS.md.

When does new Binance public data become available?

New daily data becomes available the next day, and new monthly data at the first Monday of the month. All symbols are supported.

How do I verify a Binance public data download?

Each zip has a .CHECKSUM file in the same folder. Run sha256sum -c on Linux or shasum -a 256 -c on macOS against that file.

Official sources

  1. binance/binance-public-data on GitHub
  2. Issues
  3. README
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/binance-binance-public-data.svg)](https://hysenlabs.com/projects/binance-binance-public-data)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/binance-binance-public-data.svg)](https://hysenlabs.com/projects/binance-binance-public-data)

Was this useful?