Please Note: This article is written for users of the following Microsoft Excel versions: 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365. If you are using an earlier version (Excel 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Excel, click here: Incrementing Months in Dates.

Incrementing Months in Dates

Written by Allen Wyatt (last updated October 13, 2023)
This tip applies to Excel 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365


1

Hiren has a series of dates in a worksheet. He would like to increment the month, so that (for instance) August becomes September in the dates. He wonders if there a way this can be done using Find and Replace.

You actually could use Find and Replace to do the changing. For instance, let's assume that the date shown in the cell range is 8/1/19 through 8/31/19. You could do a search for "8/" (without the quote marks) and replace it with "9/" (again, without the quotes).

There are a couple of problems with this approach, however. First, you'll end up making changes that you probably don't want to make. For instance, 8/18/19 is changed to 9/19/19 because there are two instances of 8/ in the original value. Second, when you change 8/31/19 to 9/31/19, Excel treats the converted date as text rather than as a date because 9/31 is not a valid date. In addition, you'll need to modify what you are searching for and replacing with based upon how the date is formatted in the cells.

A better solution is to use a formula to do the incrementing. The function you want to use for this purpose is EDATE, as shown here:

=EDATE(A1,1)

The formula works great at incrementing the month. You need to understand how the function works when the result of incrementing the month results in an invalid date. For instance, if the original date is 8/31/19 and you use the formula, it returns 9/30/19, the last valid day in September.

If you want, instead, to see an error when trying to increment, then the formula can be adjusted to compensate:

=IF(DAY(EDATE(A1,1))<DAY(A1),NA(),EDATE(A1,1))

This formula compares the date of the converted date to the day of the original date, and if they are not the same then it returns an #N/A error.

If you want, instead, to have the invalid date "fall over" to the next month (so that 8/31/19, when incremented, becomes 10/1/19), then you can use a different formula that doesn't rely on EDATE:

=DATE(YEAR(A1),MONTH(A1)+1,DAY(A1))

This formula will, interestingly enough, handle the "end of the year wrap" correctly. Thus, an original date in A1 of 12/1/19 will become 13/1/19 which is translated by Excel as 1/1/20.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (9265) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, and Excel in Microsoft 365. You can find a version of this tip for the older menu interface of Excel here: Incrementing Months in Dates.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

File Sizes in Word

The size of files created by Word depends on the version of the program you are using. Here's an analysis of the minimum ...

Discover More

Quickly Inserting a New Worksheet

Want a quick way to insert a worksheet? There's nothing faster than using the handy shortcut.

Discover More

Changing Text Case Many Times

Word provides a built-in shortcut to change the case of a text selection. Understanding how that shortcut works (and the ...

Discover More

Comprehensive VBA Guide Visual Basic for Applications (VBA) is the language used for writing macros in all Office programs. This complete guide shows both professionals and novices how to master VBA in order to customize the entire Office suite for their needs. Check out Mastering VBA for Office 2010 today!

More ExcelTips (ribbon)

Specifying Different Weekends with NETWORKDAYS

The NETWORKDAYS worksheet function can be used to easily determine the number of work days (Monday through Friday) within ...

Discover More

Adding Ordinal Notation to Dates

Want to add an ordinal suffix to a number, as in 2nd, 3rd, or 4th? Excel doesn't provide a way to do it automatically, ...

Discover More

Calculating a Sum for a Range of Dates

If you use Excel to track information based on dates, you may wonder how to get a sum for only certain dates that you ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 1 + 1?

2020-03-04 15:22:46

Nicholas Gray

A much more simple way to increment dates WHEN IT IS ONLY THE DAY that you want to increment is to simply add to the reference date. For example, if cell A1 contains a date and you want another date that is one week (7 days) later, the following formula will do it:
=A1+7

Note that this method is only good for adding a number of days to (or subtracting a number of days from) the referenced date.

- Nick Gray


This Site

Got a version of Excel that uses the ribbon interface (Excel 2007 or later)? This site is for you! If you use an earlier version of Excel, visit our ExcelTips site focusing on the menu interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.