How to update formula when inserting rows in Excel?

For example, I have a formula =sum(D2:D7) in cell D8. Now, when I insert a row at the second row and enter a new number, the formula automatically changes to =SUM(D3:D8), excluding cell D2, as shown in the left screenshot. In this case, I have to update the cell reference in the formula manually every time I insert rows. How could I always sum the numbers start from cell D2 when inserting rows in Excel?
Automatically update formulas in Excel to include new rows
The following formula allows you to update the sum automatically without manually adjusting cell references when inserting new rows. Follow these steps:
1. Enter this formula: =SUM(INDIRECT("D2:D"&ROW()-1)) (D2 is the first cell in the list that you want to sum) at the end of the cells that you want to sum the number list, and press Enter key.
2. And now, when you insert rows anywhere between the number list, the formula will be updated automatically, see screenshot:
Tips: The formula will only work correctly if placed at the end of the data list.
Best Office Productivity Tools
Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time. Click Here to Get The Feature You Need The Most...
Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier
- Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
- Open and create multiple documents in new tabs of the same window, rather than in new windows.
- Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!