Lean CLI

Local Development, Cloud Backtesting

An easy-to-install and use distribution of LEAN; research, backtest, optimize, and live-trade on-premise with no dependency hassles.

  • lean init
  • lean create-project "My Project"
  • lean backtest "My Project"

Installation: pip install lean

Lean more about Lean CLI right-arrow

Download Portable: Windows download Mac download Linux download

Harness The Power of LEAN Locally or in The Cloud

Seamlessly develop locally in your favorite development environment, with full autocomplete and debugging support to quickly and easily identify problems with your strategy

Cross-check your local backtests by running the same strategy in the cloud or spin up dozens of servers for batch processing a parameter optimization.

Setup Your Local Environment right-arrow

Supported IDE's

vscode visual studio pycharm rider
LEAN CLI

>_ lean backtest

>_ lean cloud backtest

Open-Source Algorithmic Trading

Get Started

Easy Synchronization

With a simple command you can synchronize your projects to the cloud to work on the go with QuantConnect's Web-IDE or to perform cross-validation of your results.

Want more processing power than your local environment? Push your code to cloud and then spin up a cluster to run your backtesting. Or pull the code down to your local computer to store backups and code version control.

LEAN CLI

>_ lean cloud push

>_ lean cloud pull

Easily Back-Up and Synchronize Strategies

Get Started

Fully Featured Tool

LEAN CLI is a feature-complete tool to leverage LEAN technology for your algorithmic trading research and trading. We carefully implement every new feature for our cloud and the CLI, ensuring the LEAN project can stand alone.

Kick off with our Getting Started Tutorial today.

LEAN CLI

>_ Feature List

  • Local / cloud backtesting
  • Autocomplete and debugging environments
  • Local / cloud optimization
  • Local / cloud live trading
  • Jupyter research environments
  • Generate or download data
  • Synchronize projects with cloud
  • Create algorithm reports

Install Lean CLI: pip install lean

The World's Leading Algorithmic Trading Platform

Install LEAN CLI

Download Financial Data

Download QuantConnect's peer-reviewed cloud financial data to run backtests and research with LEAN locally. Data is packaged and sold per symbol-day to keep costs low and can be setup to automatically download all the data you need.

Vendor Redundancy

Multiple vendors for each dataset giving you leverage to switch if needed.

Eliminate Data Wrangling

Eliminate "Extract, transform, load" processes and focus on the search for alpha.

Cleaned and Linked to Assets

All data is linked to underlying securities and automatically handles corporate actions.

Documentation, Research Notebooks, and Examples for all datasets supported

Chosen by Professionals

Deploy LEAN Today

Upgrade LEAN with Plugins

Supercharge your LEAN CLI installation with plugins from QuantConnect to popular institutional data sources and markets

Type: Data Source, Brokerage

Route orders to any of the Bloomberg EMSX network destinations and source data for your research with Bloomberg data feeds.

circle-icon Research, Backtest, and Live Data Sources

circle-icon Live Trade with LEAN through EMSX Network

circle-icon 1300+ Execution Destinations

Available with QuantConnect Subscriptions on Institutional Tier. Combine with the QuantConnect Equities Security Master for the best experience.

Type: Data Source, Brokerage

Route orders to 30+ destinations in the Trading Technologies network for best-in-class futures contract execution.

circle-icon Route to 30+ Brokerage Destinations

circle-icon Stateful Restart of Portfolio

circle-icon UAT or Live Mode Support

Available with QuantConnect Subscriptions on Trading Firm Tier. Combine with the QuantConnect Futures Security Master for the best experience.