When you add or remove rows or columns from your source data, a pivot table doesn’t automatically pick up the change—it still points to the old range. Resetting the pivot table range means updating that source reference so your pivot table includes all the new data. The fastest way is to select the pivot table, go to PivotTable Analyze > Change Data Source, and enter the new range. Below is the full step-by-step process, plus tips to avoid common pitfalls.
What You’ll Need
- An Excel workbook with a pivot table already created.
- The source data range you want the pivot table to cover (e.g., A1:D100).
- If your data is in an Excel Table, you may not need to reset the range manually—see Tips.
Step-by-Step
- Select any cell inside the pivot table. This activates the PivotTable Tools on the ribbon.
- Go to the PivotTable Analyze tab. On Windows, it’s labeled PivotTable Analyze (in some versions it may be Analyze). On Mac, look for the PivotTable Analyze tab as well.
- Click Change Data Source. In the Data group, click Change Data Source. A dialog box opens.
- Check the current range. The Table/Range field shows the current source, e.g.,
Sheet1!$A$1:$D$100. - Enter the new range. Type the new range directly, or click the collapse button (the small spreadsheet icon) to select it with your mouse. For example, if you added rows down to row 150, enter
Sheet1!$A$1:$D$150. - Click OK. The pivot table refreshes and now includes the new data.
- Refresh the pivot table. Even after changing the source, press Alt+F5 (Windows) or Command+Option+F5 (Mac) to refresh, or right-click the pivot table and choose Refresh.
Using a Named Range (alternative): If you prefer not to retype the range every time, create a named range that expands. For example, with data in A1:D100, define a name like DataRange using the formula =Sheet1!$A$1:$D$100 (or use OFFSET for dynamic expansion). Then in the Change Data Source dialog, type DataRange instead of a cell reference. This way, you only update the named range once.
Common Mistakes
- Forgetting to refresh after changing the source. Changing the range does not always immediately refresh the pivot cache; you still need to refresh the pivot table.
- Including blank rows or columns in the new range. This can create empty categories or cause errors. Always select only the data area.
- Using the wrong sheet name. If your source is on another sheet, ensure the sheet name is correct and enclosed in single quotes if it contains spaces, e.g.,
'Data Sheet'!$A$1:$D$150. - Typing the range manually with errors. A simple typo like a missing dollar sign can cause the range to shift when you copy the pivot table. Use the collapse button to select the range visually.
- Not updating all pivot tables that share the same source. If multiple pivot tables use the same data, changing one source may not affect others—you need to change each one or use a shared pivot cache.
Tips
- Convert your data to an Excel Table. Select your data and press Ctrl+T (Windows) or Command+T (Mac). Then when you create a pivot table from that table, it automatically expands as you add rows or columns. You won’t need to reset the range manually.
- Use a dynamic named range with OFFSET. For example, with data starting in A1, define a name
DynamicDataas=OFFSET(Sheet1!$A$1,0,0,COUNTA(Sheet1!$A:$A),COUNTA(Sheet1!$1:$1)). This automatically adjusts to the number of rows and columns. Note: OFFSET is volatile and can slow down large workbooks. - Refresh all pivot tables at once. Go to Data > Refresh All (or press Ctrl+Alt+F5 on Windows) to refresh every pivot table and query in the workbook.
- Check the pivot table cache. If you have multiple pivot tables from the same data, they often share a cache. Changing the source for one may update the cache for all, but not always—verify each.
Troubleshooting
The pivot table doesn’t show the new rows after changing the range. First, refresh the pivot table. If it still doesn’t appear, check that the new range actually includes the rows—look at the source data and confirm there are no filters or hidden rows. Also, ensure the new rows have data in all columns that are used in the pivot table.
I get an error: “Reference is not valid.” This usually means the range you typed is malformed or refers to a sheet that doesn’t exist. Double-check the sheet name and cell references. If you used a named range, make sure it exists and is spelled correctly.
The pivot table still uses the old range after I change it. This can happen if you have multiple pivot tables sharing a cache and you changed only one. Try changing the source for each pivot table individually, or delete and recreate the pivot table if the cache is corrupted.
My data has blank rows in the middle, and the pivot table includes them. Blank rows in the source can cause the pivot table to treat them as a separate category. Remove blank rows from your source data, or use a filter to exclude them.
After changing the range, some fields disappear from the pivot table. This may happen if the new range doesn’t include the columns that those fields were based on. Check that the new range covers all the columns you need.
Frequently Asked Questions
Q: Can I change the pivot table range without using the dialog box?
A: Yes, you can use VBA to change the source, but the dialog box is the simplest. For a quick one-time change, the dialog is recommended.
Q: Will changing the range affect my pivot table formatting?
A: No, changing the source range does not affect formatting. It only updates the data. Your layout, styles, and report filters remain intact.
Q: How do I make the pivot table automatically include new rows?
A: Convert your source data to an Excel Table (Ctrl+T). When you add rows to the table, the pivot table will include them after a refresh. Alternatively, use a dynamic named range with OFFSET.
Q: Does resetting the range work in Google Sheets?
A: In Google Sheets, you edit the pivot table’s data range by clicking the pivot table, then in the ‘Data source’ section of the editing panel, change the range. The steps differ from Excel.
Q: Can I reset the range for multiple pivot tables at once?
A: Not directly. If they share a pivot cache, changing one may update the cache. Otherwise, you need to change each pivot table’s source individually, or use VBA to loop through them.
Q: What if my data is on another sheet? Do I need to include the sheet name?
A: Yes, always include the sheet name in the range, for example 'Data'!$A$1:$D$150. If the sheet name has spaces, enclose it in single quotes.
Related
- Data Entry How to Do: Steps, Tools, and Accuracy Tips
- How to Select All Files in a Folder (Windows & Mac)
- Select All Cells in a Range: Excel & Sheets
Try it: the Percentage Formula Generator: percent of, percent change, increase and decrease, with the formula.
More in Charts & pivot tables
- How to Put Subscript in an Excel Graph Axis LabelsTo put a subscript in an Excel graph axis title, select the title text, highlight the character or…
- Excel Pivot Table Filter Not Working? Fixes That HelpIf an Excel PivotTable filter is not working, first refresh the PivotTable and check that its source data…
- Excel Waterfall Chart: Remove Connector LinesTo remove connector lines from a waterfall chart in Excel for Microsoft 365 on Windows, select the chart,…
- Combo Chart in Excel: How to Create and Use OneTo make a combo chart in Excel for Microsoft 365 on Windows, select your data, choose Insert >…
- Excel Pivot Table: Add Percentage ColumnYes, you can add a percentage column to an Excel pivot table by using the “Show Values As”…
- Sales Dashboard in Google Sheets: Build and Track ResultsYes—a sales dashboard in Google Sheets can summarize revenue, closed deals, sales by representative, and trends in one…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.