Pivot Table Issues

Summarize Excel PivotTable Data by Week, Month, Quarter, and Year

Muhammad TalhaMuhammad Talha Nov 27, 2026 871 views

Question details

Summarize daily impressions, clicks, and click-through rates by week, month, quarter, and year.

Summarize Excel PivotTable Data by Week, Month, Quarter, and Year
Product
Microsoft Excel 2007
Device & OS
not provided
Scenario
A user wants to analyze daily performance data across several time periods using a PivotTable.
Observed behavior
The desired PivotTable shows totals for each time period and a click-through rate based on total clicks divided by total impressions.
Before you start

Check that the source data has a header row and that the date column contains real Excel dates. Make sure impressions and clicks are numeric, and identify their column names before building the PivotTable.

Solution 1Recommended

Add time-period columns and build an Excel PivotTable

Use separate source columns to report by week, month, quarter, or year without relying on nested date grouping.

The formulas below assume the first date is in cell A2. Replace A2 if your date is in another column. The week formula uses Monday as the start of the week.

Calculate click-through rate from summed clicks and impressions rather than averaging daily rates. This gives each day's impressions the appropriate weight.

1
Add period headers

In the source worksheet, add columns named Week Start, Month Start, Quarter, and Year beside your existing data.

2
Enter period formulas

For the first data row, enter =A2-WEEKDAY(A2,2)+1 under Week Start, =DATE(YEAR(A2),MONTH(A2),1) under Month Start, =YEAR(A2)&" Q"&ROUNDUP(MONTH(A2)/3,0) under Quarter, and =YEAR(A2) under Year. Copy each formula down to the last data row.

3
Format the dates

Select the Week Start and Month Start columns and use Home > Number to apply a date format. Month Start represents the first day of each month, so months from different years remain separate.

4
Create the PivotTable

Select the full source range, including the new columns, and choose Insert > PivotTable. Choose where to place the report and click OK.

5
Arrange and summarize the fields

In the PivotTable Field List, drag the desired period field to Row Labels. Drag Impressions and Clicks to Values, then use Value Field Settings to select Sum for each. Swap the period field to change the reporting interval, or add fields together for a nested view.

6
Calculate the click-through rate

In a cell beside the PivotTable, divide the row's summed clicks by its summed impressions. For example, if clicks are in C5 and impressions are in B5, enter =IF(B5=0,0,C5/B5), then use Home > Number > Percent Style and copy the formula down. Adjust the cell references to match your report.

Add time-period columns and build an Excel PivotTable
Check the rate column after changes: A formula outside the PivotTable does not automatically follow every layout change. Check its references and copy it to any new rows after refreshing or rearranging the report.
Analyze data with WPS Office

Summarize performance by time period in WPS Spreadsheets

Use helper columns and a PivotTable in WPS Spreadsheets to summarize impressions and clicks by week, month, quarter, or year, then calculate the rate from the totals.

  1. 1. Open the workbook: Open WPS Spreadsheets and use File > Open to select your Excel workbook.
  2. 2. Add time-period columns: Add Week Start, Month Start, Quarter, and Year columns. If the first date is in A2, use =A2-WEEKDAY(A2,2)+1 for Week Start and =DATE(YEAR(A2),MONTH(A2),1) for Month Start. Use =YEAR(A2)&" Q"&ROUNDUP(MONTH(A2)/3,0) for Quarter and =YEAR(A2) for Year, then copy the formulas down.
  3. 3. Create a PivotTable: Select the full data range and choose Insert > PivotTable. Place the desired period field in Rows and add Impressions and Clicks to Values, using Sum for both.
  4. 4. Calculate the rate: In a cell beside the PivotTable, divide summed clicks by summed impressions. For example, enter =IF(B5=0,0,C5/B5) if impressions are in B5 and clicks are in C5, format the result as a percentage, and copy it down.
  5. 5. Save the workbook: Choose File > Save As and select an Excel-compatible format such as XLSX.
Summarize daily impressions and clicks by the time period you chooseCalculate click-through rates from aggregated totalsOpen and work with Microsoft Excel XLS and XLSX filesUse a familiar spreadsheet interface
microsoft office alternative - wps office

Frequently Asked Questions

Why should I calculate CTR from total clicks and impressions?

Total clicks divided by total impressions weights each day according to its impressions. A simple average of daily CTRs can give a misleading result when daily impression counts differ.

How do I make my weeks start on Monday?

In a source column, use =A2-WEEKDAY(A2,2)+1, replacing A2 with the date cell. Add that Week Start field to the PivotTable rows. When using the Group dialog instead, set Starting at to a Monday and group Days in intervals of 7.

Why can't Excel group my dates?

Check the source date column for blank cells, text dates, or invalid values. Correct them, right-click the PivotTable and select Refresh, then try right-clicking a date and choosing Group again.

How do I keep the same month from different years separate?

Use a Month Start helper column with =DATE(YEAR(A2),MONTH(A2),1), or select both Months and Years in the PivotTable Group dialog. Format the helper column to display the year as well as the month.

How do I update the report after adding new rows?

Copy the helper formulas into the new rows, then use PivotTable Tools > Options > Change Data Source if the new rows are outside the original range. Right-click the PivotTable and choose Refresh, and check any CTR formulas beside it.