Historical intraday stock data: what to check before a backtest

Historical minute stock data records a stock’s open, high, low, close, volume and trade count for each minute with trades. Before using it in a backtest, check the history, delisted stocks, trading hours, adjustments, timestamps and file format.

What historical intraday stock data is

Daily data has one row for each stock and day. Intraday data has the prices inside the day, as bars or as ticks.

A bar sums up one interval: its open, high, low, close, volume and trade count. Bars here come in 1-minute, 2-minute, 5-minute, 1-hour and daily timeframes. Tick data is every trade and every change in the best bid and ask.

AAPL on November 9, 2026
DataOne row isRows that day
Daily barsOne trading day1
1-minute barsOne minute with trades846
TradesOne execution750k+
QuotesOne change in the best bid or ask510k+

How far back the history goes

Free sources keep intraday history short. The yfinance documentation says that “intraday data cannot extend last 60 days”.

A backtest that should live through 2008 and 2020 needs files that start well before both. The files on this site start in September 2003.

Delisted stocks

A list of today’s tickers leaves out every company that went bankrupt, merged or was bought. A backtest on that list trades only the survivors, and its results look better than they should.

23k+ of the 36k+ tickers here are delisted, and they sit in the same files as listed stocks. Lehman Brothers is on file from September 2003 to September 17, 2008.

Pre-market and after-hours trading

US stocks trade from 4 AM to 8 PM Eastern, and the regular session runs from 9:30 AM to 4 PM. Companies report earnings before the open or after the close, so bars that stop at the closing bell miss the first reaction.

On November 9, 2026, AAPL has 276 pre-market bars, 390 regular bars and 180 after-hours bars. A minute with no trades has no bar.

Splits and dividends

A 4-for-1 split cuts a share price to a quarter overnight. Unadjusted prices show what traded on the day. Adjusted prices remove the jump, so a return measured across the split is right.

A backtest needs both: unadjusted prices to fill orders and adjusted prices to measure returns. Prices here come both ways, with the split and dividend records beside them.

Timestamps

A bar stamped 10:00 can cover the minute that starts at 10:00 or the minute that ends there. Reading one as the other shifts every signal by a minute, and the backtest then trades on prices it could not have seen.

Here a bar’s timestamp marks the start of its interval. Timestamps are integer nanoseconds since 1970 in UTC, so daylight saving never shifts them.

File format and size

1-minute bars for every US stock and ETF since 2003 take 114 GB as Parquet. Trades and quotes take 12 TB.

Parquet stores each column with its type, so a query reads only the columns it needs. CSV opens in any tool.

Load a day of 1-minute bars in Python

The free sample is one full day of AAPL. Download it, then load it with pandas.

Terminal
curl -O https://stockdataarchive.com/samples/AAPL_2026-11-09_1min.parquet
Python
import pandas as pd

bars = pd.read_parquet("AAPL_2026-11-09_1min.parquet")
bars["timestamp"] = pd.to_datetime(
    bars["timestamp"], unit="ns", utc=True
).dt.tz_convert("America/New_York")
prices = ["open", "high", "low", "close", "volume"]
bars[prices] = bars[prices].astype(float)

session = bars.set_index("timestamp").between_time("09:30", "15:59")
print(len(bars), len(session))
print(session["close"].iloc[-1])
Output
846 390
350.49

The file has 846 bars, and 390 of them fall in the regular session. The trades and quotes of the same day are free as well.

Download the data and start backtesting today.