Radically Open-Source

Algorithmic Trading Engine

DOWNLOAD LEAN DOCUMENTATION

Core Feature Set

Survivorship Bias Free

Automated accounting for splits, dividends, and corporate events like delistings and mergers

Universe Selection

Avoid selection bias with dynamically generated assets. Create and select asset universes on proprietary data and indicators.

Portfolio Management

Automatically track portfolio performance, profit and loss, and holdings across multiple asset classes and margin models in the same strategy.

Scheduled Events

Trigger regular functions to occur at desired times — during market hours, on certain days of the week, or at specific times of day.

Import Custom Data

Backtest on almost any time series and import your proprietary signal data into your strategy.

Powerful Modeling

Everything is configurable and pluggable. LEAN's highly modular foundation can easily be extended for your fund focus.

Get LEAN Today     Download Now

Rich, Extensible Modular Architecture

LEAN is modular in design, with each component pluggable and customizable. It ships with models for all major plug-in points.

Slippage and Impact

Use combinations of margin, fill, and slippage models to simulate a liquidity endpoint.

Technical Indicators

100+ popular technical indicators built, tested, and ready for use. Applicable to any data source.

Brokerage Models

Use combinations of fees, fill models, and slippage models to simulate a brokerage endpoint.

Fee Models

Customize fee models to handle rebates and dynamic order pricing.

Cash Accounts, Settlement, and Margin Models

Simulate T+3 settlement, margin trading, and cash-margin models.

Load Proprietary Datasets

Backtest and live trade on your own signals, sourced from streaming, database, or file sources.

Jump-Start Your Fund     Download LEAN

Global Open-Source Community

Join a global community of quants, engineers, and scientists choosing LEAN for their algorithmic trading. Leverage the power of open-source for your fund.

80+ Engineers

Contributing to the code base.

100 Code Samples

In C# & Python, all open-source.

1,156 Forks

Of code powering user strategies globally.

41,000 Live Algorithms

Successfully deployed live on LEAN since 2015.

2,000 Algorithms

Shared through the community forum.

6+ Months

Running live trading without interruption.


LEAN is free to download and extend for commercial purposes. QuantConnect believes in the power of a community of passionate users. Check out our manifesto.

We live this belief by making LEAN easy to use locally, and providing tutorials to ensure there is no vendor lock-in.

Join the Revolution     Download LEAN

Powered by LEAN

$1,343,800,000

Asset Volume Traded
Under LEAN

+100

LEAN-Powered Hedge Funds

Chosen by Professionals     Fork LEAN

The Algorithm Framework

LEAN Algorithm Framework bakes in key quantitative finance concepts, providing you a well-defined scaffolding as you start designing your algorithm. The framework allows you to plug in modules created by the community and radically accelerate your process.

Universe Selection

Select a universe of assets with predefined filter criteria to reduce selection bias, or pick from one of the community universe selection models to quickly get an index of the most tradable assets.

Alpha Creation

Generate an insight (expected return) for the assets you’ve selected from your universe. Fast-track algorithm development by spending the majority of your effort developing alpha insights, reusing pluggable modules for other parts of your algorithm.

Portfolio Construction

Using defined insights, create a weighted combination of assets to form your ideal portfolio. LEAN ships with pre-made portfolio-construction models for Equal Weighting, Mean Variance, and Black Litterman Portfolios.

Execution Models

Apply cutting-edge algorithms to execute your target portfolio efficiently and quickly. Pluggable framework-execution models allow you to quickly backtest different execution models and use your optimal execution strategy.

Risk Management

Adjust position sizes and manage post-trade risk with plug-in risk models. Risk models can be passive or active by hedging exposed positions as required. Combine multiple risk models to handle a range of market conditions.

Focus on What Matters     Clone LEAN

Truly Open Engine

Cross Asset

LEAN works on Equities, Forex, Options, Futures, Crypto, and CFD Assets. All assets are managed from a central portfolio, allowing you to trade on all 6 asset classes at the same time.

Cross Platform

Seamlessly deploy to Windows, Mac OS, and Linux Platforms.

Cross Language

Write algorithm strategies in C#, F#, and Python.

Harness LEAN     Download Now

Powerful Data Integrations and Toolbox

LEAN ships with a rich toolbox of adaptors and plug-ins: the open-source LEAN ToolBox.

Visual Studio Integration

Code locally in Visual Studio and backtest in the cloud with QuantConnect data and computing. Monitor your backtests from your Visual Studio control window.

Jupyter Lab Integration

Iterate rapidly in a LEAN-Enabled Jupyter Lab command line environment with rich strategy backtest reports.

Live Stream Data Sources

Take advantage of bundled implementations to many streaming data sources: IQFeed, Interactive Brokers, IEX Exchange, OANDA, FXCM, RabbitMQ, and GDAX.

Historical Data Downloaders

Download data from popular online repositories and brokerages: Dukascopy, FXCM, OANDA, GDAX, Kraken, Interactive Brokers, Google Finance, and Yahoo Finance.

How Does LEAN Work?

Get Started with LEAN Today     Open GitHub