Backtest Lab Docs

Broker Profile

A Broker Profile defines the trading costs, margin requirements, and other broker-specific rules used when executing trades during a backtest.

These settings allow Backtest Lab to account for expenses and capital requirements that affect trading results beyond the movement of share prices.

During the current beta, Backtest Lab provides a single broker profile: Backtest Lab Default.

Leverage and Margin

The default broker profile uses different leverage assumptions depending on the trade type.

Trade TypeLeverageCapital Required
Buy Intraday5×20% of trade value
Sell Intraday5×20% of trade value
Buy Delivery1×100% of trade value

For example, opening an intraday position worth ₹50,000 requires ₹10,000 of trading capital, excluding transaction charges.

Delivery trades do not receive leverage, so the full trade value must be funded.

Sell Delivery trades are not supported in Backtest Lab.

Transaction Charges

Backtest Lab applies transaction charges once, when a trade is entered. No additional charges are applied when the trade is closed.

The charges depend on the type of trade being opened and consist of two components:

  • Brokerage: The broker's charge for entering a trade, inclusive of applicable GST.
  • Exchange-Related Charges: Additional costs calculated as a percentage of the trade's entry turnover.

The following charges are used by the Backtest Lab Default broker profile:

Trade TypeBrokerageExchange-Related Charges
Buy IntradayLower of 0.0354% of turnover or ₹23.600.009145% of turnover
Sell IntradayLower of 0.0354% of turnover or ₹23.600.034043% of turnover
Buy Delivery₹00.140243% of turnover

How Charges Are Calculated

Transaction charges are calculated using the value of the trade when it is entered.

Entry Turnover = Entry Price × Quantity

For intraday trades, brokerage is calculated as:

Brokerage = Minimum of (Entry Turnover × 0.0354%, ₹23.60)

Exchange-related charges are calculated separately using the applicable rate for the trade type.

Total Transaction Charges = Brokerage + Exchange-Related Charges

These charges are deducted at trade entry and are included in the calculation of the trade's net profit or loss.

No additional transaction charges are applied when the trade is exited, regardless of how or when the exit occurs.

Broker Assumptions

The rates and leverage values above represent the execution assumptions used by Backtest Lab's default broker profile.

They are intended to provide consistent transaction cost and capital calculations during backtesting and may differ from the actual charges or margin requirements of a particular broker.

The default broker profile uses a simplified transaction cost model in which all charges are applied at trade entry. Real-world brokers may charge separately for entry and exit transactions.

Additional broker profiles may be introduced in future versions of the platform.