When I started in data engineering, I thought cost was somebody else’s job. Then a manager pulled me aside, pointed at a monthly figure for our data platform, and asked a gentle question: what does one run of your pipeline cost? I stared at her. I knew how long it took, how many rows it moved, and which tables it touched. I had no idea what it cost. If that sounds like you, this primer is for you, and it ends with a small glossary to keep nearby.
Why the monthly total is a poor teacher
A monthly bill for your data platform is a sum of many small things: storage, compute that wakes up for each job, queries run by analysts, data moved between systems. Looking at the sum is like looking at a grocery receipt without the item list. You know you spent a lot, and you cannot tell whether it was the cheese or the delivery fee.
So beginners are often told to cut costs, and they respond by guessing. They shut off a job that someone needed, or they spend a week tuning something that barely mattered. The cure for guessing is a unit: a recognisable thing you can divide the total by. In data work the friendliest units are the pipeline run, the gigabyte processed, and the query.
Picking your first unit
Start with the pipeline run. It is something you already count, since your scheduler tells you how many ran. Divide the compute cost attributed to that pipeline over a month by the number of runs, and you have a first, rough cost per run. Do not worry about precision yet. The point is to give the number a name your team can say out loud.
Once you have it, a few natural questions follow, and they are more useful than any chart.
- Is every run the same size, or do a few huge runs pull the average up?
- Does the pipeline reprocess data that has not changed?
- Does anything run more often than the people who read the output actually need?
A story from a small team
On one team I worked with, a transformation job ran every hour because it always had. When someone divided its monthly cost by its runs and then asked who read the results, the answer was one weekly report. Nobody had ever connected those two facts. The job was not broken. It simply was not matched to the way people used it, and nothing on the monthly bill could have shown that.
The fix was a conversation rather than a clever trick. The report owner said daily would be fine. The engineer changed the schedule. Everyone moved on with a better picture of what a run was worth. If you want practice on the transformation layer itself, there is a good walkthrough on building data transformations with dbt that will show you where a run begins and ends.
What really moves the cost of a run
Beginners often assume the cost depends mostly on how much data flows through. Sometimes it does. Often the bigger drivers are quieter.
- Repeated work. Rebuilding a whole table every time when only a small part changed.
- Checks that run too widely. Quality tests are valuable, but running every one on every table in every run has a price. See the discussion of validating data with Great Expectations for ideas on choosing where checks pay off.
- Idle capacity. Compute that starts early or stays on long after the job ends.
- Movement. Copying data between regions or systems when it could have stayed put.
None of these is a mistake in itself. Each is a choice, and unit cost is simply a way of seeing what each choice adds.
Where the cost conversation belongs
It is tempting to treat cost as an engineering chore. In practice it works best when the people who pay and the people who build look at the same unit together. That shared practice has a name, FinOps, and learning it formally can help a young team skip a few painful years. FinOpsSchool teaches FinOps and runs certification programmes, so people from engineering and finance can study how to bring cloud costs into plain view.
Mini-glossary
A handful of terms you will meet when you start talking about unit cost.
- Unit cost. The total cost of something divided by how many of that thing you produced, such as one run or one gigabyte.
- Pipeline run. One complete execution of a data job from start to finish.
- Allocation. The rule you use to share a common cost, like a shared warehouse, across the teams or pipelines that use it.
- Idle cost. Money spent on capacity that is switched on but doing no useful work.
- Driver. The thing that makes a cost go up or down, such as run frequency or data volume.
- Showback. Telling teams what their usage costs without actually charging them.
Your first week with this
You do not need approval or a new tool to begin. On Monday, pick one pipeline. On Tuesday, find its monthly cost and its run count. On Wednesday, divide, and write the result somewhere visible. On Thursday, ask who reads the output and how often. On Friday, share what you found with one colleague and one person from the business side, and ask what surprised them.
I still remember the small embarrassment of that first question from my manager. I would not trade it. It taught me that a number becomes useful the moment it has a face, and that asking what one thing costs is not a trap. It is the kindest way to understand a system that has grown bigger than anyone can hold in their head. Start small, keep it rough, and let the questions lead you.