Compare · method vs method

Excel formulas vs Power Query:
what 10,000 rows actually costs

Every article on this topic argues from opinion. This one argues from a stopwatch. We built the same job twice — a rebate lookup that has to keep working as orders arrive — and timed the formula version at six sizes, from 100 rows to 10,000. The result is not what the usual advice predicts: the formula column is not slow, it is rented. It charges 17.35 microseconds per row, forever, and the charge does not get cheaper as you scale.

Per row, marginal
17.35 μs
flat from 500 rows to 10,000 — this is the number that never improves
10,000 rows
173.54 ms
measured in the engine on this page, not in Excel
Formula cells created
10,000
each one an object to audit, recalc and migrate
100,000 rows, extended
~1,710 ms
linear extension of the measured floor, labelled everywhere as an estimate
See the measured cost curve When you should not switch
VFormulas rent row by row. Power Query buys the scan once.

At 10,000 orders, the formula column costs 173.54 ms of engine work to fill and keep. That is fast enough that nobody notices. The problem is what that number is made of: 10,000 separate formula cells, each one a small permanent tenant that has to be audited, recalculated, migrated and explained. Power Query does the same job with one query and one written column, so the 10,001st order costs you a row, not a row plus a formula. Neither approach is wrong. They have different shapes of cost, and most people pick by fashion instead of by shape.

It flips when two things are true at once: the table keeps growing after you build it, and someone other than you has to audit the logic later. Miss either one and the formula column wins on speed of setup, portability and the fact that it still works in Google Sheets.

The cost curve that never expires

One job: add a Rebate column to an order table, where every order row looks up its customer's rebate in a reference table on a second sheet. The formula build puts an =XLOOKUP() in every row. Each row is written, then read back, so the timer includes evaluation and not just string insertion. Same data every run, seeded, so the numbers are reproducible rather than anecdotal.

RowsFormula cellsMeasured costTimePer rowvs 100Source
100100
9.93 ms99.26 μs×1.00measured
500500
19.37 ms38.74 μs×1.95measured
1,0001,000
20.69 ms20.69 μs×2.08measured
2,0002,000
39.35 ms19.67 μs×3.96measured
5,0005,000
86.67 ms17.33 μs×8.73measured
10,00010,000
173.54 ms17.35 μs×17.48measured
50,00050,000
~855 ms17.35 μs—linear estimate
100,000100,000
~1,710 ms17.35 μs—linear estimate

← swipe the table sideways on a phone →

The number that matters is not 173 ms

Look at the per-row column instead. It falls from 38.7 μs at 500 rows to 17.35 μs at 10,000 — and then it stops falling. That floor is the real price of one more order, and it does not improve with scale, better hardware, or a newer Excel. Extend that floor linearly and 100,000 rows lands at roughly 1,710 ms of engine work per full recalculation. That figure is an extension, not a measurement, and it is labelled as such in the table above. The transferable fact is the shape: a flat per-row charge with no expiry date, which is a very different thing from a slow formula.

What each approach actually owns

Columns three and four are not milliseconds. Power Query cannot be executed inside HyperFormula, so pretending to time it would make every number on this page worthless. What follows is what each approach structurally owns, written as facts you can check against the product rather than results of a run.

DimensionFormula columnPower Query
Cost grows when data growsyes — one more formula per new rowno — one more row into one query
Where the logic livesspread across N cellsone Applied Steps list
Reading it back in 6 monthsclick cells one by oneread step names top to bottom
Error message quality#N/A in one cell among thousandsstep name + offending row
Undo blast radiusthe cellthe query (re-runnable)
Runs with the workbook closednono
Runs in Google Sheetspartly (no XLOOKUP in older Sheets)no
Mac Excelfullyes, editor is Windows-first
Someone else can audit itharder as N growseasier
Ties you to Excelno — formulas exportyes — M is Excel-only

What was timed, and what was not

This is the honesty clause, and it is also the reason this page is worth reading. We measured the formula side because we can. We did not measure the Power Query side because it does not run in a browser engine, and a fabricated millisecond is worse than an absent one. If you need a refresh-time comparison on your own file, the only valid method is to build both and time them in your Excel, with your data, on your machine — and that is a twenty-minute experiment, not an article.

Myth check: whole-column references

The most repeated piece of spreadsheet advice is that whole-column references like =SUMIFS(D:D,B:B,A2) are slow and you should always write exact ranges. We ran it both ways, five times per size, and took the median. The engine stores sparse data, so an empty tail costs almost nothing to skip.

RowsExact rangeWhole columnScaleRatioSame answer
5000.49 ms0.49 ms
1.01×✓ identical
2,0000.97 ms2.28 ms
2.36×✓ identical
5,0002.05 ms2.05 ms
1.00×✓ identical

We could not reproduce the whole-column slowdown

Ratios came out at 1.01×, 2.36× and 1.00× with identical results in every run. In this engine, whole-column references are not reliably slower, and at 5,000 rows the difference vanished. That does not mean exact ranges are pointless — they are self-documenting, they survive someone inserting a total row at the bottom, and they behave predictably in Excel's own dependency tracker. But if you are hunting for the reason a workbook feels slow, this is not where the milliseconds are. They are in the per-row formula count, which is the first table on this page.

Moving one column to Power Query

The realistic version of the switch: not "rewrite everything", but "move the one column that keeps growing". Five moves, in the order that keeps the workbook working at every step.

What you doFormula columnPower QueryNote
Turn the range into a tableSelect A1:F5001, Insert → TableSame step — query needs a table source. Do this first even if you never open Power Query.This one step is worth doing alone: it makes every later range self-expanding.
Get the reference table inLeave it as a range, reference it in 10,000 formulasData → Get Data → From Table/Range → close & load as Connection OnlyConnection Only means it does not add a sheet; the join reads it directly.
Do the lookup=XLOOKUP(B2,Tiers!$A$2:$A$31,Tiers!$C$2:$C$31,0) filled downMerge Queries → Customer = Name → Expand → RebaseOne step. It replaces every occurrence of the formula at once.
Handle unmatched customersIFNA(XLOOKUP(...),0) — wrap every row, or accept #N/AThe merge leaves null; Add Column → Replace Values → 0A null in a merge is visible as null, not as a red cell you have to hunt for.
Load and keep it freshNothing to do — it recalculates when Excel feels like itClose & Load To… → Table, then Data → Refresh (or Refresh on Open)The trade: refresh is explicit. Formulas are implicit. Pick the one you can remember to do.

When you should not switch

Four situations where the formula column is the correct answer, and moving to Power Query costs you more than it saves.

case 1Your table has fewer than ~2,000 rows and will never grow

Below that size the formula column costs single-digit milliseconds and the setup cost of a query (plus explaining M to whoever inherits the file) is larger than the entire saving. Optimising a 400-row sheet is a hobby, not engineering.

case 2The file has to work in Google Sheets

Power Query does not exist there. If the workbook lives in two ecosystems, the formula column — written with SUMIFS rather than XLOOKUP — is the only version that survives the trip. Choose portability over elegance when the file travels.

case 3A Mac user has to maintain it

Power Query runs on Mac Excel, but the editor is Windows-first and the experience differs enough that most Mac users will not touch it. A solution the maintainer will not open is not a solution.

case 4It is a one-off analysis

If you need the answer today and the file will be archived on Friday, the formula column is correct. Power Query pays back over refreshes. A one-shot has no second refresh to pay it back with.

Questions with measured answers

Is 173 ms for 10,000 rows good or bad?
Neither — that number is engine-specific and this page says so in the table. What transfers is the shape: 17.35 microseconds per row, flat. On your machine the multiplier will differ, but it will still multiply by row count, and it will still not improve as the table grows. Read the curve, ignore the digits.
So which one is faster?
The formula column is faster to build. Power Query is faster to keep. Those are the only two speed claims this data supports. A single refresh in Power Query scans the data once; a formula column re-evaluates N cells on every recalculation. At small N that is invisible. At large N it is a tax you pay per recalculation, not per row — which is why the felt experience depends on how often your workbook recalculates.
Does Power Query make the file smaller?
It removes the formula cells but adds a query definition and a loaded table, so file size is roughly a wash. What shrinks is the dependency graph and the audit surface: one query versus thousands of cells. If your pain is a slow save or a confused colleague, that is the number that matters, and it is not milliseconds.
Can I mix them?
Yes, and most mature workbooks do. Keep the presentation layer in formulas — the live dashboard, the scenario toggles, the things a human nudges. Put the growing joins and cleanups in queries. The failure mode to avoid is the opposite: a query that only exists to feed one cell, and a thousand formulas that only exist to re-do a join.
Why not just measure Power Query too?
Because this page runs on a browser spreadsheet engine, and Power Query is not part of one. Any site that shows you "Power Query: 240 ms" measured in a browser is showing you a number it did not produce. We would rather show you the formula side for real and the structural side as structure.
Methodology. Every millisecond on this page comes from HyperFormula 3.5, the engine that powers the live grids on this site, running the same seeded dataset you see described above. Each measurement writes a formula into a cell and reads the result back, so evaluation is inside the timer. The 100,000-row figure is a linear extension of the measured per-row floor and is marked as an estimate wherever it appears. Power Query was not timed at all: it is not executable in this engine. Scope, per-row costs and the full run are preserved in the page's Dataset schema, which you can read, diff and cite.