Capex to Operating Cash Flow Ratio

Calculate the capital expenditure to operating cash flow ratio, the share of the cash from operations that a company reinvests in property, plant and equipment.

What is not reinvested is the free cash flow, so one minus this ratio is the free cash flow to operating cash flow ratio. A ratio near or above 1 means the company spends all its operating cash on investments, as capital intensive and fast growing companies do.

The formula is as follows:

\[\text{Capex to Operating Cash Flow} = \frac{\left|\text{Capital Expenditure}\right|}{\text{Cash Flow from Operations}}\]

Capital expenditure is reported as a negative cash outflow, so its magnitude is used. A cash flow from operations of zero or less gives NaN. It is the inverse of the capital expenditure coverage ratio (get_capex_coverage_ratio).

Also known as: capex to OCF, capex to cash flow from operations, reinvestment of operating cash flow.

Example · TSM, INTC, MSFT · 2021 to 2025

Install the Finance Toolkit with pip install financetoolkit -U, then call get_capex_to_operating_cash_flow_ratio:

from financetoolkit import Toolkit

toolkit = Toolkit(
    ["TSM", "INTC", "MSFT"],
    api_key="FINANCIAL_MODELING_PREP_KEY",
    start_date="2021-01-01",
    end_date="2025-12-31",
)

toolkit.ratios.get_capex_to_operating_cash_flow_ratio()

Or, with the Finance Toolkit MCP set up, ask an AI assistant such as Claude or ChatGPT:

What share of their operating cash flow did TSMC, Intel and Microsoft spend on capital expenditure from 2021 to 2025?

Which returns:

Parameters

get_capex_to_operating_cash_flow_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. The window counts calendar periods, so a period without a report makes it NaN. Defaults to None, which uses single-period flows (per quarter and not annualized with quarterly data).4
show_columnsstr | list[str] | NoneThe columns to keep, a name or a list of names, matched on every column level, or the rows when no column has those names (such as the line items of a financial statement). Names that do not exist are logged, and when none exist the result is returned in full. Defaults to None, which keeps every column.None, which keeps every column
Share