Calculate the Force Index for a given price series.

The Force Index is an indicator that measures the strength behind price movements.

The formula is as follows:

\[\text{Raw Force Index} = (\text{Close} - \operatorname{Close}(1)) \cdot \text{Volume}\] \[\text{Force Index} = \operatorname{EMA}(\text{Raw Force Index},\; \text{window})\]

Also known as: FI, Elder’s Force Index.

No programming experience? With the Finance Toolkit MCP server, AI assistants such as Claude and ChatGPT can calculate the Force Index for you. Just ask in plain English.

Calculate the Force Index in Python

The Force Index is available in the Technicals module of the open-source Finance Toolkit. Install it with:

pip install financetoolkit -U

Then call get_force_index as shown below.

from financetoolkit import Toolkit

toolkit = Toolkit(tickers=["AAPL", "MSFT"])

toolkit.technicals.get_force_index()

Which returns:

Date AAPL MSFT Benchmark
2026-06-18 1.5469e+09 2.64103e+08 5.23308e+09
2026-06-22 -7.46954e+08 -6.39817e+09 -2.13467e+09
2026-06-23 -2.04451e+09 3.52532e+09 -1.02007e+10
2026-06-24 -9.23144e+08 -4.57591e+09 -3.22888e+08
2026-06-25 -1.46857e+10 -7.31369e+09 1.01111e+09
2026-06-26 8.76398e+09 1.47121e+10 -4.94319e+09
2026-06-29 -2.04817e+09 -3.2984e+09 1.1285e+10
2026-06-30 7.61233e+09 3.37872e+09 5.23673e+09
2026-07-01 5.00175e+09 8.72373e+09 -9.03283e+08
2026-07-02 1.4666e+10 4.77999e+09 -8.48204e+08

Parameters

get_force_index accepts the following parameters:

  • period (str, optional): The time period to consider for historical data. Can be “daily”, “weekly”, “quarterly”, or “yearly”. Defaults to “daily”.
  • close_column (str, optional): The column in the historical data that represents the closing prices. Defaults to “Adj Close”.
  • window (int, optional): The number of periods for calculating the Force Index. Defaults to 14.
  • rounding (int | None, optional): The number of decimals to round the results to. Defaults to 4.
  • growth (bool, optional): Whether to calculate the growth of the indicator values. Defaults to False.
  • lag (int | list[int], optional): The lag to use for the growth calculation.
  • standardize (bool, optional): Whether to standardize (Z-Score) the result. When combined with growth=True, standardizes the growth values instead of the raw values. Defaults to False. Defaults to 1.

The Technicals module page introduces the module, and the sidebar lists all of its functions.

Share