Excel data tables can mean two different things: structured Excel Tables that organize lists of records, or What-If Analysis data tables that compare formula results under different inputs. Use a structured Table to manage everyday data; use a What-If Data Table to test one or two changing assumptions against a calculation.
Two Excel features called data tables
The shared name causes understandable confusion. A structured Table is a worksheet range with features such as filterable headers, automatic expansion, and column-based formulas. It is useful for lists of orders, inventory, contacts, or transactions. A What-If Analysis data table is a scenario tool: Excel substitutes a series of values into one or two input cells and records the resulting formula outputs in a grid.
They are not interchangeable. A structured Table helps you store and analyze records, while a What-If Data Table answers questions such as “How does revenue change if price or sales volume changes?” A What-If Data Table is also different from a PivotTable, which summarizes and rearranges data that already exists rather than repeatedly recalculating a model with trial inputs.
What a structured Excel Table does
Turning a range into a Table gives the range a recognized structure. Each column has a header, and Excel can provide filter and sort controls, consistent formatting, and a Total Row. When you add a record directly below the Table, Excel commonly expands it; formulas and formatting can also carry into the new row. Expansion behavior can depend on how data is added and on Excel settings, so check the Table boundaries after pasting large blocks.
Tables also make formulas easier to read through structured references. Instead of referring only to cell addresses, a formula can identify a column by its header and, within a Table row, refer to the current row’s value. This makes a formula more understandable when the Table grows or columns move. Tables are especially handy when the same dataset feeds charts, formulas, or PivotTables.
Create and format a structured Table
On Excel for Microsoft 365 for Windows, select a cell in the data range and choose Insert > Table, or press Ctrl+T. Check the range in the dialog, select My table has headers if the first row contains column names, and choose OK. On Mac, use Insert > Table or Command+T. Excel for the web also supports creating and working with Tables, though some desktop controls and workflows differ.
For a reliable result, prepare the range first:
- Give every column a distinct, descriptive header, such as Date, Product, Quantity, or Unit Price.
- Keep one kind of information in each column and one record in each row.
- Avoid completely blank rows or columns inside the dataset, merged cells, and separate title rows within the selected range.
- Check that dates and numbers are stored as values of the appropriate type, not as text that merely looks like a date or number.
Clicking in the finished Table reveals the Table Design tab on Windows. There you can rename the Table, select a style, and turn options such as the Header Row, Banded Rows, and Total Row on or off. A useful name such as SalesData is easier to work with than Excel’s default Table1. The Total Row can offer common summaries, including a sum or average, for a selected column.
Use structured references in formulas
Suppose a Table named Orders has columns Quantity, Unit Price, and Line Total. With those exact headers in the Table, enter this formula in a Line Total data cell:
=[@Quantity]*[@[Unit Price]]
Excel interprets the references as the values from the current row. It may automatically fill the formula down the whole calculated column. The nested brackets around Unit Price are needed because the header contains a space. If the Table is renamed or a header changes, Excel generally updates structured references that point to it.
To total all line totals, put this formula in a cell outside the Table:
=SUM(Orders[Line Total])
This reference means the Line Total column in the Orders Table. If records are added to that Table, the column reference includes them, unlike a fixed range that might stop at the old final row. Structured references are not mandatory: ordinary cell references still work, and they may be preferable for a quick calculation or a layout that is not a proper dataset.
What-If Analysis data tables
A What-If Data Table creates a compact sensitivity analysis around a formula. Excel takes each trial value from a row or column, temporarily places it in a chosen input cell, recalculates the dependent formula, and displays the result. A one-variable data table changes one input cell across many trials. A two-variable data table changes two input cells, testing combinations from a row of values and a column of values.
For example, imagine a simple revenue model. Suppose B2 contains price per item, B3 contains units sold, and B4 is the revenue result. With price in B2 and units sold in B3, enter this formula in B4:
=B2*B3
A one-variable table could show the revenue at different prices while holding units sold at the current value. A two-variable table could show revenue across a range of prices and quantities. These tables do not save a separate copy of the model for every scenario; they recalculate the model using the trial inputs and display the outputs.
Set up a one- or two-variable data table
For a one-variable example, assume the model uses B2 for price, B3 for units, and B4 for revenue. Put a reference to the output formula in D1, put trial prices across E1:H1, and place the data-table result area below those values. Select the full grid containing the output reference, trial values, and empty result cells. Choose Data > What-If Analysis > Data Table. Because trial prices are across a row, set Row input cell to B2, then select OK. Excel fills the result cells with revenue for each trial price.
If the trial values are arranged vertically instead, use the Column input cell field and choose B2. The input cell must be the cell the model actually uses; it should not be a formula cell that calculates the output. For a two-variable table, place one set of trial values across the top, the other down the first column, and the output formula reference at their intersection. Select the entire grid, open the Data Table dialog, then assign the row input cell to the model input represented by the top row and the column input cell to the input represented by the first column.
Data tables are array-style calculation areas rather than ordinary records. Their result cells are controlled by the data-table operation, so do not expect to edit each output as an independent formula. They are most useful for a small, clear model with one or two key assumptions. Microsoft 365 desktop Excel for Windows provides the stated ribbon path; Excel for the web may display workbook content but is not the right place to build or change this What-If feature. Use desktop Excel when the Data Table command is unavailable in your environment.
Choose the right kind of table
Start with the question you want to answer. If you need to sort a sales list, filter by region, add rows, or write a formula for every transaction, use a structured Table. If you already have a calculation and want to see how its output responds to several trial values, use a What-If Data Table. If you need to group a large record set by category and summarize totals, a PivotTable may be the better tool.
- Structured Table: best for managing a growing list and using formulas tied to column names.
- What-If Data Table: best for comparing repeated results from one or two model inputs.
- PivotTable: best for summarizing and reorganizing existing records across categories.
- Separate scenario calculations: useful when cases require different formulas, notes, or more than two changing assumptions.
A common misconception is that a What-If Data Table is simply a formatted Table with values. Formatting a range does not make it perform scenario calculations, and converting a range to a structured Table does not create a What-If analysis. Choose the feature based on the task, not on the word “table.”
Common problems and practical limits
If a structured Table does not include new data, check whether the new rows are actually inside its boundary. Use Table Design > Resize Table to adjust the range when needed. Also confirm that the header row was identified correctly and that column names are unique. A blank or inconsistent header can make formulas harder to understand, while numbers stored as text can produce confusing totals.
If a What-If Data Table returns unexpected values, verify the output formula and make sure the selected row and column input cells match the model inputs. Check that the formula depends on those cells; changing an unrelated cell will not affect the result. Review the orientation too: values across the top correspond to the Row input cell, and values down the first column correspond to the Column input cell.
Large What-If tables can slow recalculation because Excel evaluates the model repeatedly for each combination. If calculation becomes sluggish, reduce the number of scenarios or simplify formulas used by the model. On Windows, Formulas > Calculation Options includes Automatic Except for Data Tables, which can reduce repeated recalculation while you work. Remember to recalculate the workbook when needed, and avoid relying on stale results when inputs have changed.
Frequently Asked Questions
How do I make a data table in Excel?
For a normal, filterable dataset, select it and choose Insert > Table, or press Ctrl+T on Windows. For scenario testing, build a formula model and use Data > What-If Analysis > Data Table.
What is the difference between an Excel Table and a data table?
An Excel Table organizes records and supports features such as structured references and filters. A What-If Data Table calculates results for trial values in one or two model input cells.
Can an Excel data table use more than two variables?
A What-If Data Table can vary one or two input cells, not three or more. For more assumptions, use separate scenario calculations, a scenario-management approach, or a suitable model design.
Why is the Data Table option unavailable?
Check that you are using desktop Excel and have selected a properly arranged output grid for a What-If Data Table. The command is not the same as Insert > Table, and the web app may not offer the desktop creation workflow.
Do Excel Tables expand automatically?
They commonly expand when you type immediately below the last row or add adjacent data, but behavior can vary with the action and settings. If a new record is left out, use Table Design > Resize Table to include it.
Related
- Budget Spreadsheet With Rollover: How It Works
- UK Budget Spreadsheet: Build a Practical Monthly Plan
- Embed a SharePoint Video in PowerPoint: What Works
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Unhide Columns in Excel Using the KeyboardIn Excel for Microsoft 365 on Windows, select the columns on both sides of the hidden area, then…
- Excel Consolidate Lists With Duplicates: Keep or Remove?To combine lists and keep repeated items in Excel for Microsoft 365 on Windows, enter =VSTACK(A2:A5,B2:B4) in an…
- Test Excel Data: Practical Checks for Accuracy and ErrorsTo test Excel data, check for missing values, duplicates, invalid entries, and formulas that do not match the…
- What Is a Definition Update? Meaning & UsesA definition update is a change made to the stored meaning of a term, word, or concept within…
- Convert Excel to ZIP: How to Compress and Share a WorkbookTo put an Excel workbook in a ZIP file on Windows, open File Explorer, right-click the workbook, and…
- Track Changes in Word: A Step-by-Step GuideTo track edits in Word, open the document, select Review > Track Changes, and then edit as usual.…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.