
Sometimes when we import data from another source in to excel, the dates are not imported properly. This can be due to any number of reasons, including,
- The date format is different from one that is understood by excel
- The data has some extra spaces, other characters before and after the date values.
- The dates are formatted for another country (or date system) and hence your version of Excel wont recognize them.
- The separator between date, month and year is not a known separator (for eg. 12=DEC=2009 instead of 12-Dec-2009), etc.
In this post, we will learn some tricks and ideas you can use to quickly convert text to dates.
Technique 1: Use Text to Columns Utility
- First copy the source data and paste it in a text file (open Notepad and paste there).
- Now copy the values from text file and paste them in Excel.
- At this point, Excel will prompt you for using “Text to columns” utility (or Text Import Wizard as it is called in Excel 2007)

- Go to the Text Import Wizard (or Text to Columns dialog).
- Leave defaults or make changes in step 1 & 2.
- In step 3, select “Date” and specify the format of the date – like YMD, MDY, DMY, YDM, MYD or DYM. It doesn’t matter what is the format of source date, month or year is. Excel can smartly understand them.

- Click “Finish”.
That is all. Your text dates are now converted to excel understandable dates.
Technique 2: Using Formulas to Convert Text to Dates
- Paste the data in a column (say “A”)
- Now depending on the format of source data, write one of the below formulas to convert text to dates.
Using DATEVALUE formula
DATEVALUE formula tells excel to fetch the date from a given input. It is a smart formula capable of converting dates stored as text to excel understandable date format. To convert a text in cell A1 to date, you just write =DATEVALUE(A1)
However, DATEVALUE formula has some limitations. It cannot process all types of dates. For eg. I have shown a few sample dates along with corresponding DATEVALUE output.

Readjusting Date Text so that it works with DATEVALUE formula
Whenever possible, your next best option is to re-adjust the source data text so that it can be understood by DATEVALUE formula. Here is an example.

We can use the text formulas like LEFT, RIGHT and MID to extract portions of the date text and then regroup them using & operator to create meaningful date text format that would be understood by DATEVALUE formula.
Technique 3: Using DATE formula to Convert Text to Dates
If your data has separate columns for date, month and year, you can use DATE formula to convert the data to dates like this:
=DATE(year,month,day)
For eg. =DATE(2009,12,31) will give the date 31st December, 2009.
Bonus Technique: Converting Dates to Text
If you want to convert excel dates to text values (for your report or some other purpose), you can use the TEXT formula like this:
=TEXT(A1,"DD-MMM-YYYY") will convert date in Cell A1 to DD-MMM-YYYY format. You can pass any other date / time formats to TEXT formula as well. [more: tutorials on TEXT() formula]
How do you deal with troublesome dates?
Of course, if it is a real date, we can always bolt. But if it is a date in the data, we need some tools to deal with it. I used to rely on formula based methods to clean the dates. But recently I discovered the import-text date conversion method. This is very powerful and straightforward. Now, I use it whenever possible to clean up my date data.
What about you? How do you deal with buggy / faulty dates in Excel?
Recommended Articles:














23 Responses to “Learn Top 10 Excel Features”
What it looks like if excel without formula?? 🙂
It would be not excel it would just be fancy tables in which you could just use power point. (Chandoo) would Access be an alternative?
Awesome piece of work!!!
Great article.
Chandoo - my biggest interest in the article was the awesome word-graphic at the top - where did you go to get it done into a shape?
@Rich.. thank you. I used http://www.tagxedo.com/ to generate this word cloud. I took all the comments in the original post, pasted them in tagxedo website and set up the shape etc.
Awesome Chandoo.. You need always needs coffee to start up with. BTW , how did u created the Heart Shaped picture filled with High Repetitive text in it .. Please put it on your Next blog ...
Chandoo, good article. I’ve added a link to it from Connexion – our collection of the most useful and interesting spreadsheet-related articles from the web. See http://www.i-nth.com/resources/connexion
Hi,
Just one small question. Where the hell have been I in the past for not discovering this website sooner?
I've lost a job interview recently where even though I had the subject knowledge, I was not upto their mark in Excel.
Thank you for all the free tips, guidance and for creating this forum environment.
[PS: I've just been through the site for the 1st time, and have signed up for the newsletter. You can expect pretty stupid questions from me soon]
Hy Chandoo, you always inspire me with to explore something new in excel. This data structure table is only for excel 2007 or compatible to 2010. I recently installed latest excel version 2013 in my System and experience problems regarding operating according to previous one. I'm waiting your article relates to that excel version.
Thanks
Awesome article Mr. Chandoo and that is a awesome heart shaped pic you created. Great tips as well.
[...] Learn Top 10 Excel Features | Chandoo.org – Learn Microsoft Excel Online. [...]
Chandoo is awesome..
Thanks, i got better, And i always get 90.50 in my grade card but now i get 96.50 i improved because of the tutorials you gave, Thank You Very Much Chandoo Guy.
Hi chandoo, i am intersted in seeing the video or step by step done procedure of analysing the comments and presenting in the data percentage steps. I think this one would be first step in finding out how generally happens data calculation. Thank you.
As well i would like to know how to get that black shape art of your face which i see in chandoo. I am interested in making it for me.
Nice to see the features considered by Excel users to be most useful. It might be a good idea to also analyze StackOverflow Excel questions to see what keywords appear most often.
Here are my top 10 Excel Features (for advanced users):
http://www.analystcave.com/excel-10-top-excel-features/
Thanks a ton for this it totally helped with my homework ????
Very good effort
Thank you for this. Lots of learning in the links you've provided for this septuagenarian.
Pls send me new post
Dude, your humor ? ?
Loved your work.
Hello Sir,
I am Sanjeev Khakre and i from Indore City, India , I am your big follower and i have watch your videos and learnt a lots of excel trick or function and many more . thanks so much for all of your excellent support.
Your excel knowledge is real awesome.
Thanks
Sanjeev
Your work is excellent but pls willing to know more details about the features of microsoft excel
Chandoo Would Access be a better alternative than VB?