If you change any of the data in your source worksheet, the pivottable will update automatically.

If you change any of the data in your source worksheet, the pivottable will update automatically.

If you make changes to the source data a PivotTable is based on, the PivotTable isn’t automatically updated. Instead, you must manually refresh the PivotTable anytime you change its underlying source data.

Manually Update a PivotTable

  1. Make a change to the PivotTable’s source data.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  2. Navigate to the PivotTable.
  3. Click any cell inside the PivotTable.

    The PivotTable Tools are displayed on the ribbon.

  4. Click the Analyze tab on the ribbon.
  5. Click the Refresh button.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

    Alt + F5 also refreshes the PivotTable.

The PivotTable is refreshed and pulls in any changes made to the source data.

If you have more than one PivotTable in your workbook and you want to update them all at once, instead click the Refresh button’s list arrow and select Refresh All from the menu.

Automatically Update a PivotTable

You can also have Excel refresh the PivotTables in a workbook when a file opens

  1. Click the PivotTable button on the Analyze tab.
  2. Click Options.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

    The PivotTable Options dialog box displays. In addition to setting the PivotTable to refresh when opened, there are also various options here for PivotTable settings, such as assigning a name; changing the layout, format, and display settings; and adding alt text.

  3. Click the Data tab.
  4. Check the Refresh data when opening the file check box.
  5. Click OK.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

Now any PivotTables in the workbook will automatically refresh each time you open the file.

If you change any of the data in your source worksheet, the pivottable will update automatically.

FREE Quick Reference

Click to Download

Free to distribute with our compliments; we hope you will consider our paid training.

Lesson 27: Intro to PivotTables

/en/excel/inspecting-and-protecting-workbooks/content/

Introduction

When you have a lot of data, it can sometimes be difficult to analyze all of the information in your worksheet. PivotTables can help make your worksheets more manageable by summarizing data and allowing you to manipulate it in different ways.

Optional: Download our practice workbook.

Watch the video below to learn more about PivotTables.

Using PivotTables to answer questions

Consider the example below. Let's say we wanted to answer the question What is the amount sold by each salesperson? Answering it could be time consuming and difficult; each salesperson appears on multiple rows, and we would need to total all of their different orders individually. We could use the Subtotal command to help find the total for each salesperson, but we would still have a lot of data to work with.

If you change any of the data in your source worksheet, the pivottable will update automatically.

Fortunately, a PivotTable can instantly calculate and summarize the data in a way that will make it much easier to read. When we're done, the PivotTable will look something like this:

If you change any of the data in your source worksheet, the pivottable will update automatically.

Once you've created a PivotTable, you can use it to answer different questions by rearranging—or pivoting—the data. For example, let's say we wanted to answer What is the total amount sold in each month? We could modify our PivotTable to look like this:

If you change any of the data in your source worksheet, the pivottable will update automatically.

To create a PivotTable:

  1. Select the table or cells (including column headers) you want to include in your PivotTable.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  2. From the Insert tab, click the PivotTable command.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  3. The Create PivotTable dialog box will appear. Choose your settings, then click OK. In our example, we'll use Table1 as our source data and place the PivotTable in a new worksheet.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  4. A blank PivotTable and Field List will appear in a new worksheet.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  5. Once you create a PivotTable, you'll need to decide which fields to add. Each field is simply a column header from the source data. In the PivotTable Fields list, check the box for each field you want to add. In our example, we want to know the total amount sold by each salesperson, so we'll check the Salesperson and Order Amount fields.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  6. The selected fields will be added to one of the four areas below. In our example, the Salesperson field has been added to the Rows area, while Order Amount has been added to Values. You can also drag and drop fields directly into the desired area.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  7. The PivotTable will calculate and summarize the selected fields. In our example, the PivotTable shows the amount sold by each salesperson.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

Just like with normal spreadsheets, you can sort the data in a PivotTable using the Sort & Filter command on the Home tab. You can also apply any type of number formatting you want. For example, you may want to change the number format to Currency. However, be aware that some types of formatting may disappear when you modify the PivotTable.

If you change any of the data in your source worksheet, the pivottable will update automatically.

If you change any of the data in your source worksheet, the PivotTable will not update automatically. To manually update it, select the PivotTable and then go to Analyze > Refresh.

Pivoting data

One of the best things about PivotTables is that they can quickly pivot—or reorganize—your data, allowing you to examine your worksheet in several ways. Pivoting data can help you answer different questions and even experiment with your data to discover new trends and patterns.

To add columns:

So far, our PivotTable has only shown one column of data at a time. To show multiple columns, you'll need to add a field to the Columns area.

  1. Drag a field from the Field List into the Columns area. In our example, we'll use the Month field.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  2. The PivotTable will include multiple columns. In our example, there is now a column for each person's monthly sales, in addition to the grand total.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

To change a row or column:

Changing a row or column can give you a completely different perspective on your data. All you have to do is remove the field in question, then replace it with another.

  1. Drag the field you want to remove out of its current area. You can also uncheck the appropriate box in the Field List. In this example, we've removed the Month and Salesperson fields.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  2. Drag a new field into the desired area. In our example, we'll place the Region field under Rows.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  3. The PivotTable will adjust—or pivot—to show the new data. In our example, it now shows the amount sold by each region.

    If you change any of the data in your source worksheet, the pivottable will update automatically.

To learn more:

Once you're comfortable with PivotTables, review our Doing More with PivotTables lesson for additional ways to customize and manipulate data.

Challenge!

  1. Open our practice workbook.
  2. Create a PivotTable in a separate sheet.
  3. We want to answer the question What is the total amount sold in each region? To do this, select Region and Order Amount. When you're finished, your workbook should look like this:

    If you change any of the data in your source worksheet, the pivottable will update automatically.

  4. In the Rows area, remove Region and replace it with Salesperson.
  5. Add Month to the Columns area.
  6. Change the number format of cells B5:E13 to Currency. Note: You might have to make columns C and D wider to see the values.
  7. When you're finished, your workbook should look like this:

    If you change any of the data in your source worksheet, the pivottable will update automatically.

/en/excel/doing-more-with-pivottables/content/

Does a PivotTable update automatically?

By default, PivotTables are not refreshed automatically, but you can specify that the PivotTable is automatically refreshed when you open the workbook that contains the PivotTable.

When there are changes in the source worksheet PivotTables update automatically?

Since your Pivot Table is created using the Pivot Cache, when the existing data changes or when you add new rows/columns to the data, the Pivot Cache does not update itself automatically, and hence, the Pivot Table also does not update. You need to force a refresh every time there are changes.

How do you update a PivotTable after changing the source data?

A quick and easy way to refresh a pivot table after the data changes is to manually update it: Right-click any cell in the pivot table, then click on Refresh.

Does a PivotTable automatically refresh when the underlying data is updated or changed?

PivotTables require a refresh if the underlying data is changed or added to. This tutorial will explain how to automatically refresh your PivotTable using a few lines of VBA code. The solution will work when you change existing data or add new data.

What happens to the source data when the PivotTable layout is changed?

The data source for the PivotTable will be changed to the selected Table/Range of data.