EnableYourData.com

KPI · Marketing

Marketing ROI: formula and example.

Marketing ROI, also known as ROMI, is the gross profit attributed to marketing, minus marketing costs, divided by marketing costs. A marketing ROI of 100% means every euro of marketing returns one extra euro of profit on top of recovering its cost. It answers whether marketing as a whole pays off.

Marketing ROI formula

(Gross margin on revenue attributed to marketing − marketing costs) ÷ marketing costs × 100%

Worked example

In 2025, Acme Groothandel spent €180,000 on marketing. Revenue of €1,200,000 was attributed to marketing, at a 30% gross margin, so €360,000. Marketing ROI is (€360,000 − €180,000) ÷ €180,000 × 100% = 100%.

Fictitious figures for Acme Groothandel, a sample wholesaler.

How to read this KPI

Above 0%, marketing pays for itself; below 0%, it costs more than it returns. The result depends heavily on which revenue you attribute to marketing, so record that choice and keep it constant. Compare marketing ROI by year and by channel, and for repeat customers also look at value over several years.

Pitfalls with marketing ROI

  • Using revenue instead of gross margin, which makes the ROI far too high.
  • Attributing all revenue from customers who ever came in through marketing to marketing.
  • Counting ad spend only and leaving out staff, agencies and tools.

SQL & DAX

Calculating marketing ROI in SQL and DAX

Two examples on a fictitious data warehouse for Acme Groothandel: a PostgreSQL query and a measure for a Power BI model. Adjust table and column names to your own model.

SQL · PostgreSQL
WITH margin AS (
  SELECT date_trunc('year', o.order_date) AS year,
         SUM(ol.quantity * (ol.unit_price - ol.unit_cost) - ol.discount_amount)
           / NULLIF(SUM(ol.quantity * ol.unit_price - ol.discount_amount), 0) AS margin_rate
  FROM order_lines ol JOIN orders o USING (order_id) GROUP BY 1),
attributed AS (
  SELECT date_trunc('year', spend_date) AS year, SUM(conversion_value) AS revenue
  FROM ad_spend GROUP BY 1),
cost AS (
  SELECT date_trunc('year', month) AS year, SUM(amount) AS cost
  FROM marketing_costs GROUP BY 1)
SELECT year, a.revenue, c.cost,
       ROUND(100.0 * (a.revenue * m.margin_rate - c.cost) / NULLIF(c.cost, 0), 1) AS marketing_roi_pct
FROM attributed a JOIN cost c USING (year) JOIN margin m USING (year)
ORDER BY year;
DAX · Power BI
Marketing ROI =
VAR MarginRate =
    DIVIDE(
        SUMX(SalesLines, SalesLines[Quantity] * (SalesLines[UnitPrice] - SalesLines[UnitCost])),
        SUMX(SalesLines, SalesLines[Quantity] * SalesLines[UnitPrice])
    )
VAR Cost = SUM(MarketingCosts[Amount])
RETURN
    DIVIDE(SUM(AdSpend[ConversionValue]) * MarginRate - Cost, Cost)

In ENABLE

Tracking this KPI in ENABLE

Plain-language questions

Ask for marketing ROI per month, customer or product in the SQL Explorer with AI. The AI writes the SQL, you see the query and run it yourself; the AI only receives metadata.

Read more →

In your Power BI dashboard

Define the KPI as a measure in your Power BI model and show it in the portal, with "Last refreshed" next to it. Access profiles and optional row-level security decide who sees which figures.

Read more →

Custom dashboards (pilot)

Add the KPI as a tile to a custom dashboard, compared with last year. The Dashboard Builder is a pilot and can be switched on per client.

Read more →

Monthly targets

With the built-in Targets app you set a target for the KPI per month, so you see actuals and target side by side.

Read more →

FAQ

Frequently asked questions

How do you calculate marketing ROI?

Take the gross margin on revenue attributed to marketing, subtract marketing costs and divide the result by marketing costs. With €360,000 in margin and €180,000 in costs, marketing ROI is 100%. Use margin rather than revenue, otherwise you compare income with costs while ignoring the cost of goods.

What is the difference between marketing ROI and ROAS?

Marketing ROI is about profit and all marketing costs, while ROAS is about revenue and ad spend only. ROAS is suited to comparing campaigns; marketing ROI to judging the total marketing budget. A high ROAS does not guarantee a positive marketing ROI.

Which revenue should you attribute to marketing?

Which revenue you attribute to marketing depends on your attribution model, for example last click or spread across several touchpoints. No model reflects reality exactly. Pick one, document it and only compare years using the same model.

Use AI on your own data. Securely, and without the headache.

In an online demo we show how ENABLE makes your data securely available and how you build on it: describing an app in the AI Builder, plain-language questions, dashboards and APIs. And how we set it up and manage it for you.