TradingView Intraday History
TradingView intraday history and how to extend it
TradingView intraday history on a chart covers a limited window. How much intraday history a chart loads depends on the user's TradingView plan. For statistics like gap fills, opening range or VWAP, a short window can bias results. FinzData provides 1-minute bars for US stocks and ETFs since January 2000 and for futures since 2007 so the same calculation can be measured over decades. This guide shows how to measure overnight gap fill rates on SPY 1-minute bars since 2000 in pandas.
The chart window problem
TradingView is a popular charting platform and trading community; Pine Script is its scripting language for indicators and strategies. Charts are excellent for real-time visualization and idea sketching. For research, the amount of intraday bars available on a chart is constrained. That makes long-term intraday statistics difficult to compute inside the platform.
Exporting the data or using an external source removes the window constraint and lets you compute statistics consistently across years. TradingView intraday history is useful for recent context, but research often needs a much longer sample.
Pine Script cannot request data from external websites or APIs; scripts work with data available on TradingView. To extend the window, pull the bars with FinzData and run the calculation in Python.
What FinzData provides for intraday
FinzData is a market-data API and Python client that mirrors yfinance. Install with pip install finzdata, import finzdata as yf. The client returns pandas DataFrames. REST API at https://api.finzdata.com returns JSON or CSV; Parquet and bulk files on paid plans.
Coverage includes 16,000+ US stocks since January 2000 including delisted names, 231 ETFs, daily, hourly, 30-, 15-, 5- and 1-minute bars. Intraday bars are stamped at the start of each interval in US Eastern time; minutes without trades are omitted, never forward-filled. Futures: 139 markets, 17,605 individual contracts since 2007, daily to 1-minute bars, back-adjusted and raw continuous series with the roll calendar.
Point-in-time universe ensures you are measuring on the stocks that actually traded on each date, avoiding survivorship bias when you compute long-term intraday statistics.
Measure overnight gap fill rates on SPY
import finzdata as yf
import pandas as pd
t = yf.Ticker("SPY")
bars = t.history(start="2000-01-01", interval="1m")
bars = bars.dropna(subset=["Open","Close"])
# Daily open and prior close
daily_open = bars["Open"].resample("D").first()
prev_close = bars["Close"].resample("D").last().shift(1)
gap_pct = (daily_open - prev_close) / prev_close * 100
# First 60 minutes high/low
first_hour = bars.groupby(bars.index.date).head(60)
high_1h = first_hour["High"].groupby(first_hour.index.date).max()
low_1h = first_hour["Low"].groupby(first_hour.index.date).min()
filled_up = high_1h >= daily_open
filled_down = low_1h <= prev_close
filled = filled_up | filled_down
stats = pd.DataFrame({"gap_pct":gap_pct,"filled":filled})
print(stats["filled"].mean())
stats.to_csv("spy_gap_fill_rate.csv")Why long windows matter
Intraday statistics computed on a short window can be misleading. With TradingView intraday history limited by plan, a gap fill rate measured on the last few months may not reflect behavior over a full market cycle. FinzData lets you compute the same metric on 1-minute bars since 2000 for US stocks and ETFs, and since 2007 for futures.
Long windows allow you to test regime dependence, seasonality and robustness. You can also compare opening range behavior across bull and bear markets, or measure VWAP reversion over decades.
Because intraday bars are stamped at the start of each interval in US Eastern time and minutes without trades are omitted, calculations remain consistent and reproducible.
From chart to reproducible research
Sketch the idea in Pine Script, then pull the same symbols from FinzData and run the calculation in pandas. The Python client supports yf.Ticker, yf.history, yf.download and yf.Client().c.prices for bulk access. Results can be saved to CSV for Excel or imported into NinjaTrader 8.
Every subscriber gets access to the FinzData strategies page and research, including the AI Trading Tournament. Use the research library to benchmark your intraday statistics against published work.
Free tier includes last 12 months of every dataset, 1,000 API calls a day, no card. Full history is a one-time purchase that is yours to keep.
Start free
Start with the free tier to test TradingView intraday history alternatives on recent data, then purchase full history for long-term research. Explore samples and pricing to plan your workflow.
Frequently asked questions
Is TradingView intraday history the same as FinzData?
No. How much intraday history a chart loads depends on the user's TradingView plan. FinzData provides 1-minute bars for US stocks and ETFs since January 2000 and futures since 2007.
Can I use Pine Script with FinzData?
Pine Script cannot request data from external websites or APIs; scripts work with data available on TradingView. Use FinzData in Python for backtesting outside the chart.
Are intraday bars adjusted?
Intraday bars are stamped at the start of each interval in US Eastern time; minutes without trades are omitted, never forward-filled. Futures series are available back-adjusted and raw with roll calendar.
Do you provide point-in-time data?
Yes. Point-in-time universe provides the stocks that actually traded on each date.
What is the free tier?
Free tier includes last 12 months of every dataset, 1,000 API calls a day, no card.