In the Pricing page I see that I can get hour/daily data with Free plan but LEAN CLI is only usable with a paid one, so how do I get the data with Free plan?
QUANTCONNECT COMMUNITY
In the Pricing page I see that I can get hour/daily data with Free plan but LEAN CLI is only usable with a paid one, so how do I get the data with Free plan?
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Mia Alissi
I’ll show you two Free-plan workflows that don’t use the LEAN CLI:
Per QuantConnect docs, you can request Hourly/Daily history in the cloud, while using the LEAN CLI with QuantConnect datasets requires being on a paid tier. I’ll include ready-to-run code for both workflows next. citeturn0search1turn0search0turn0search3
Now I’ll generate the code.You’re right: with the Free plan you can access Hourly and Daily history in the QuantConnect Cloud, but the LEAN CLI with QuantConnect datasets requires a paid tier. That means you should pull the data in the Cloud (Backtests or Research) and then download the CSVs, rather than via the CLI on Free.
Two easy Free-plan workflows
1) Cloud backtest “exporter” (no CLI)
2) Cloud Research notebook
I’ve generated ready-to-run code for both options below.
Cloud backtest exporter (Python) Copy this into a new Cloud project’s main.py and Run Backtest. It will export CSV(s) to output/ and quit immediately.
from AlgorithmImports import * class ExportHistoryAlgorithm(QCAlgorithm): """ Exports Hourly or Daily historical bars for a list of tickers to CSV files in the project's output/ folder. No trading logic — it fetches data in Initialize() and quits. """
Cloud Research notebook snippet (Python) Run this in a new Research notebook cell; CSVs will appear in output/.
from AlgorithmImports import *
QuantBook research snippet to export Hourly/Daily history to CSVs in the project's output folder. How to download in Cloud IDE: - After running, open the left panel > Files > output/ and click the CSV files to download. Note: Timestamps are in the algorithm time zone (America/New_York by default). Instantiate QuantBookqb = QuantBook()
-------------------- User settings -------------------- Tickers to fetch_tickers: list[str] = ["SPY", "QQQ", "AAPL"]
Resolution: Resolution.HOUR or Resolution.DAILY_resolution: Resolution = Resolution.HOUR
Date range_start: datetime = datetime(2015, 1, 1) _end: datetime = datetime(2025, 10, 24)
Include extended market hours for intraday bars_extended_market_hours: bool = False
Data normalization mode_normalization: DataNormalizationMode = DataNormalizationMode.ADJUSTED
------------------------------------------------------- Add equities with chosen settings and set normalization per security_symbols: list[Symbol] = [] for t in _tickers: try: equity = qb.add_equity(t, _resolution, extended_market_hours=_extended_market_hours) if equity is None: continue equity.set_data_normalization_mode(_normalization) _symbols.append(equity.symbol) except Exception as add_err: print(f"Skipping {t}: {add_err}")
if len(_symbols) == 0: raise Exception("No symbols were added. Check tickers and settings.")
Request history for all symbols at oncehist = qb.history(_symbols, _start, _end, _resolution)
if hist is None or (hasattr(hist, "empty") and hist.empty): print(f"No history returned for {_symbols} from {_start} to {_end} at {_resolution}.") else:
Notes and gotchas
If you must use the LEAN CLI on Free
If you tell me your tickers, dates, and whether you want Hourly or Daily, I can tailor the snippets to your exact request.
Sources: Getting Started - QuantConnect.com, US Index Options - QuantConnect.com, US Futures - QuantConnect.com, Rendering Data with Notebooks - QuantConnect.com, Empty Equity And Options400 Benchmark
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Jared Broad
Free data is only available in the cloud platform
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Long
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!