EnableYourData.com

KPI · Marketing

Cost per lead: formula and example.

Cost per lead (CPL) is your marketing spend in a period divided by the number of new leads in that period. A lead is a contact who leaves their details, for example through a quote request or a download. It shows how efficiently your campaigns generate new contacts.

Cost per lead formula

Marketing spend in the period ÷ number of new leads in the period

Worked example

In September, Acme Groothandel spent €12,600 on LinkedIn and Google ads and received 180 new leads. Cost per lead is €12,600 ÷ 180 = €70.

Fictitious figures for Acme Groothandel, a sample wholesaler.

How to read this KPI

A lower cost per lead means you acquire new contacts more cheaply, but not necessarily better ones. Compare CPL by channel and campaign, and always alongside lead-to-opportunity rate: an expensive lead that often becomes a customer can work out cheaper than a cheap one that never buys. Track CPL over several months rather than judging a single month.

Pitfalls with cost per lead

  • Counting ad spend only and leaving out agency fees, tools and content without saying so.
  • Counting duplicate leads and existing customers as new leads.
  • Comparing channels on CPL alone without looking at lead quality.

SQL & DAX

Calculating cost per lead 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 cost AS (
  SELECT date_trunc('month', month) AS month, SUM(amount) AS marketing_cost
  FROM marketing_costs GROUP BY 1),
new_leads AS (
  SELECT date_trunc('month', created_at) AS month, COUNT(*) AS leads
  FROM leads GROUP BY 1)
SELECT month, marketing_cost, leads,
       ROUND(marketing_cost / NULLIF(leads, 0), 2) AS cost_per_lead
FROM cost
JOIN new_leads USING (month)
ORDER BY month;
DAX · Power BI
Cost per Lead =
DIVIDE(
    SUM(MarketingCosts[Amount]),
    COUNTROWS(Leads)
)

In ENABLE

Tracking this KPI in ENABLE

Plain-language questions

Ask for cost per lead 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 cost per lead?

Divide marketing spend for a period by the number of new leads in the same period. With €12,600 in spend and 180 leads, CPL is €70. Decide which costs you include, so months and channels remain comparable.

What is the difference between cost per lead and cost per acquisition?

Cost per lead is the cost per new contact, while cost per acquisition is the cost per conversion you have set as your goal, such as a purchase or a signed quote. A lead sits early in the funnel, an acquisition usually further along. Cost per acquisition is therefore almost always higher.

How can you lower your cost per lead?

You lower cost per lead by shifting budget to channels and campaigns that generate leads more cheaply, and by improving the conversion of your landing pages. Sharper targeting stops you paying for clicks from people who will never become customers. Keep an eye on lead quality while you do this.

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.