Calculate the inventory turnover ratio, an efficiency ratio that measures how quickly a company sells its inventory.

The inventory turnover ratio is calculated by dividing the cost of goods sold (COGS) by the average inventory value. It indicates how many times a company’s inventory is sold and replaced over a period. A higher inventory turnover ratio suggests that a company is effectively managing its inventory by quickly converting it into sales.

The formula is as follows:

\[\text{Inventory Turnover Ratio} = \text{Cost of Goods Sold} / \text{Average Inventory}\]

Inventory turnover is only comparable within an industry: a grocer turns its stock many times a year, a maker of aircraft or luxury goods a few times at most. Analysts watch the trend and the gap with peers, since a falling ratio often comes before markdowns or write-downs. Because the ratio divides cost of goods sold by inventory, the inventory valuation method (LIFO or FIFO) and year-end stock building for a peak season both move it; quarterly data with trailing=4 smooths the seasonal effect.

Also known as: stock turnover ratio.

Inventory Turnover Ratio in Python or via the MCP

Install the Finance Toolkit with:

pip install financetoolkit -U

Then call get_inventory_turnover_ratio as shown below.

from financetoolkit import Toolkit

toolkit = Toolkit(
    ["HD", "LOW", "TSCO"],
    api_key="FINANCIAL_MODELING_PREP_KEY",
    start_date="2021-01-01",
    end_date="2025-12-31",
)

toolkit.ratios.get_inventory_turnover_ratio()

Or, after setting up the Finance Toolkit MCP, ask:

How many times a year did Home Depot, Lowe's and Tractor Supply turn over their inventory from 2021 to 2025?

Which returns:

  2021 2022 2023 2024 2025
HD 5.1854 4.4565 4.4354 4.7811 4.458
LOW 3.7987 3.5865 3.2481 3.2532 3.3076
TSCO 4.1535 3.7678 3.4834 3.4585 3.4987

Parameters

get_inventory_turnover_ratio accepts the following parameters.

ParameterTypeDescriptionExample
roundingint | NoneThe number of decimals to round the results to. Defaults to None, which uses the rounding of the Toolkit (4 unless set otherwise).2
growthboolWhether to calculate the growth of the ratios. Defaults to False.True
lagint | list[int]The lag to use for the growth calculation. Defaults to 1.4
compoundboolWhether the growth is the compound annual growth rate over the lag (e.g. lag=5 for the five-year CAGR) instead of the total change. Defaults to False.False
standardizeboolWhether to standardize (Z-Score) the result. When combined with growth=True, standardizes the growth values instead of the raw values. Defaults to False.True
trailingintThe number of periods to sum flows (income and cash flow statement items) over, with balance sheet items averaged over the same number of period ends. E.g. 4 with quarterly data gives the trailing twelve months (TTM) and 3 with annual data a three-year cumulative figure. Defaults to None, which uses single-period flows (per quarter and not annualized with quarterly data).4
Share