Skip to content
Workflow · Track and forecast · Opening soon

Cost per lead by channel

Export your ad spend by channel, new leads by source, and source to channel map from HubSpot. The workflow matches the source keys, adds the mapped channel, totals spend and leads by month, then calculates cost per lead for each channel.

Early access opens shortly. Check back soon.

Someone typed

“calculate cost per lead by channel each month from ad spend and new leads by source”

The agent read it as

Calculate cost per lead by channel each month from HubSpot ad spend by channel and HubSpot new leads by source, using HubSpot source to channel map.

What the agent built

7 steps, each one an ordinary Mammoth step you can open and change.

  1. File
    HubSpot ad spend by channel
    CSV export · 24 rows
  2. File
    HubSpot new leads by source
    CSV export · 26 rows
  3. File
    HubSpot source to channel map
    CSV export · 6 rows
  4. Step
    Total spend by month
    Step 5
  5. Step
    Make source key (New leads)
    Step 2
  6. Step
    Make source key (Source map)
    Step 1
  7. Join
    Add mapped channels
    24 of 26 paired
  8. Step
    Total leads by month
    Step 4
  9. Join
    Match monthly channels
    24 of 24 paired
  10. Step
    Calculate cost per lead
    Step 7
  11. Result
    Monthly Channel Lead Cost
    25 rows
  12. Schedule
    Runs when you say
    Proposed

On the sample files, every step runs and the result has 25 rows.

What you get back

The result of that run, the rows to look at first.

Monthly Channel Lead CostSample data25 rows
ChannelMonthCost per leadAd spendNew leads
direct2026-08-010019
display2026-08-0168.422,60038
organic_social2026-08-010052
paid_search2026-08-0150.628,200162
paid_social2026-08-0144.635,400121
partner2026-08-0134.151,40041
referral2026-08-010034
display2026-09-01·2,8000
organic_social2026-09-010058
paid_search2026-09-0152.309,100174
paid_social2026-09-0142.966,100142
partner2026-09-0138.461,50039
25 rows in the result · 12 shown, problems first. Sample data: illustrative figures, not business results.

How it works

How to use the Monthly Channel Lead Cost workflow

  1. 1Get early accessWe invite people in small batches, job by job. You'll land on this workflow, already built and working on sample files.
  2. 2Swap in your exportsUpload your own files as they come out of your tools. The agent checks the workflow on your rows.
  3. 3Change it in words, then turn it onSay what to change and see the new result before anything saves. Then choose when it runs.

Monthly Channel Lead Cost: questions

How do you calculate cost per lead by channel each month?
Export your ad spend by channel, new leads by source, and source to channel map from HubSpot. The workflow matches the source keys, adds the mapped channel, totals spend and leads by month, then calculates cost per lead for each channel. You get monthly channel cost per lead as the result.
What export should you use?
Use exported files for ad spend by channel, new leads by source, and a source to channel map from HubSpot. The workflow reads those spreadsheet-style files and uses them together.
What happens to rows that do not match?
Rows that do not match the mapping or the monthly channel totals do not appear in the final matched result. You can review the unmatched rows in the input files and update the mapping or source values.
How do you change the rules?
Edit the steps in words, for example change the source map, the month grouping, or the channel matching rule. Then run the workflow again on the exported files.

Get early access to this workflow

It opens already built and working on sample files. Swap in your own exports to see your result.

Early access opens shortly. Check back soon.

Workflows like this

The number you report every month, rebuilt from the latest export, plus the forecast that follows from it.

All track and forecast workflows →