What a sensitivity table does and why you'd build one

A sensitivity table (also called a data table) lets you see how the result of a formula changes when you alter one or two of its inputs. Instead of manually changing numbers and recalculating, you set up a table that does this automatically — showing you all the outcomes at once.

The most common use is financial: you have a formula that calculates profit, loan payment, or investment return based on certain assumptions. A sensitivity table shows you what happens if those assumptions shift. For example, if your formula calculates monthly mortgage payment based on interest rate and loan amount, a sensitivity table can show you every combination of rates and amounts in a single grid.

Excel has two types of data tables. A one-variable table changes a single input and shows how the result changes. A two-variable table changes two inputs at once and shows the outcome for each combination. Most people use one-variable tables because they're simpler to set up and easier to read.

Key Takeaways

  • A one-variable data table requires your formula in one cell, a column or row of input values, and the Data Table feature under the Data menu.
  • Set up the table by placing your formula in the top-left corner, then list input values either down the left column or across the top row.
  • Select the entire table range (formula plus all input values and blank cells where results will appear), then go to Data > What-If Analysis > Data Table.
  • For a one-variable table, enter the cell reference of the input you want to change in either the Row Input Cell or Column Input Cell field, depending on whether your inputs run across or down.
  • A two-variable table shows outcomes for two changing inputs at once, but requires more setup and is harder to read than running two separate one-variable tables.

Setting up a one-variable table with inputs down the left column

Start with a formula that you want to test. For example, suppose cell B2 contains =A2*1.15, which multiplies a sales figure by 1.15 to show a 15% increase. You want to see what the result would be if the original sales figure (in A2) were different values: $10,000, $15,000, $20,000, and so on.

In a blank area of your spreadsheet, create the table structure. Put your formula in the top-left cell — let's say cell E2. Below it, in cells E3 through E6, leave them blank (Excel will fill these with results). To the left, in cells D3 through D6, type the input values you want to test: 10000, 15000, 20000, 25000.

Now select the entire range from E2 to E6 (the formula cell plus the blank cells below it and the input values to the left). Go to the Data menu, click What-If Analysis, then click Data Table. In the dialog box that appears, leave the Row Input Cell blank. In the Column Input Cell field, type the cell reference of the input you want to change — in this case, A2. Click OK. Excel fills in the blank cells with the results.

Setting up a one-variable table with inputs across the top row

If you prefer your input values to run left to right instead of top to bottom, the setup is similar but reversed. Put your formula in the top-left cell. To the right of it, in the same row, type your input values: 10000, 15000, 20000, 25000. Below the formula, leave cells blank where the results will go.

Select the entire range from your formula cell across to the last input value, and down to the last row where results will appear. Open the Data menu, click What-If Analysis, then Data Table. This time, leave the Column Input Cell blank. In the Row Input Cell field, type the cell reference of the input you want to change. Click OK.

The choice between these two layouts is purely visual — pick whichever is easier for you to read and fits better on your spreadsheet.

Building a two-variable table to test two inputs at once

A two-variable table shows outcomes when two different inputs change. For example, if your formula calculates monthly payment based on both interest rate and loan amount, a two-variable table shows payment for every combination of rates and amounts.

Put your formula in the top-left cell. Along the top row (to the right of the formula), list one set of input values — say, interest rates: 3%, 4%, 5%, 6%. Down the left column (below the formula), list the other set of input values — loan amounts: 100000, 150000, 200000, 250000. Leave all other cells in the table blank.

Select the entire rectangular range from your formula cell through all the input values and blank cells. Open Data > What-If Analysis > Data Table. In the Row Input Cell field, enter the cell reference for the input that runs across the top (the interest rate cell). In the Column Input Cell field, enter the cell reference for the input that runs down the left side (the loan amount cell). Click OK. Excel fills the grid with results for every combination.

Two-variable tables are powerful but can be hard to read if you have many input values. If you find yourself squinting at the results, consider running two separate one-variable tables instead — one showing how payment changes with rate (holding amount constant), and another showing how it changes with amount (holding rate constant).

Updating and editing your data table

Once you've created a data table, Excel recalculates it automatically whenever the formula or any input value changes. If you want to change the input values themselves (for example, test different interest rates), simply edit the cells containing those values. The table updates immediately.

If you want to change which input the table tests, you need to delete the table and create a new one. Select the range, go to Data > What-If Analysis > Data Table, and change the Row Input Cell or Column Input Cell reference. Do not try to edit the table manually — the cells contain array formulas that Excel manages, and editing them directly will break the table.

If you want to convert the results to static numbers (so they no longer update if the formula changes), select all the result cells, copy them, then paste them as values only using Paste Special.

Common mistakes and how to avoid them

The most frequent error is selecting the wrong range. You must include the formula cell, all input values, and all the blank cells where results will appear. If you select too small a range, Excel won't have room for all the results. If you select too large a range, you'll get error values in the extra cells.

Another common mistake is entering the wrong cell reference in the Row Input Cell or Column Input Cell field. Double-check that you're pointing to the cell in your original formula that you actually want to change — not a cell that contains a label or a different value.

Some people try to create a data table with the formula in a different location than the top-left corner of the range. Excel requires the formula to be in the top-left cell of the selected range. If your layout doesn't match this, move the formula or rearrange your input values.

When to use a data table versus other tools

A data table works well when you want to see many outcomes at once in a static grid. If you need to change inputs frequently and see results update in real time, a data table is fine but not special — you could also just edit the formula inputs directly.

If you want to find the specific input value that produces a target result (for example, "what interest rate gives me a $500 monthly payment?"), use Goal Seek instead. Go to Data > What-If Analysis > Goal Seek, enter your target value, and Excel finds the input that produces it.

If you want to test many different scenarios with different formulas or multiple changing inputs, consider building a separate calculation area where you manually set up different scenarios. This gives you more flexibility than a data table, though it requires more work.

Frequently Asked Questions

Can I create a data table that tests more than two inputs at once?

No. Excel's data table feature handles one or two inputs only. If you need to test three or more inputs, build multiple two-variable tables (one for each pair of inputs), or set up separate calculation scenarios in different areas of your spreadsheet.

Why does my data table show #REF! errors?

This usually means the cell reference you entered in the Row Input Cell or Column Input Cell field doesn't exist or is invalid. Check that you typed the reference correctly and that the cell you're pointing to is part of your original formula. If you deleted or moved the original formula, the data table breaks.

Can I delete some rows or columns from a data table without breaking it?

No. A data table is a single array formula, so deleting part of it breaks the whole thing. If you want fewer input values, delete the entire table and create a new one with only the inputs you need.

How do I make my data table show currency or percentage formatting?

Select the result cells (not the input values), then format them as you normally would — right-click and choose Format Cells, or use the formatting buttons in the toolbar. The data table itself doesn't control formatting; you apply it to the cells after the table is created.

What's the difference between a data table and a pivot table?

A data table tests different inputs against a single formula and shows outcomes. A pivot table reorganizes and summarizes existing data from a list or database. They solve different problems — use a data table for what-if analysis, and a pivot table for summarizing data.