Convert Date to YYYYMMDD

Sathsaj

New Member
Joined
Sep 2, 2015
Messages
23
Hi I would like to convert a date =today() to YYYYMMDD format.
Is there a way, most of the search shows YYYYMMDD to other formats.
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
If you just want to change the look, but keep it as a valid date, you can simply put =TODAY() in the cell and apply a custom format to the cell of "YYYYMMDD".
If you want it to be a text value, and not date, use the formula:
Excel Formula:
=TEXT(TODAY(),"YYYYMMDD")
 
Upvote 0
1- Inspection Plan Log.xlsx
E
4220230815
Sheet3
Cell Formulas
RangeFormula
E42E42=TODAY()

1692104722593.png
 
Upvote 0
If you just want to change the look, but keep it as a valid date, you can simply put =TODAY() in the cell and apply a custom format to the cell of "YYYYMMDD".
If you want it to be a text value, and not date, use the formula:
Excel Formula:
=TEXT(TODAY(),"YYYYMMDD")
when I use this formula do you why I get YYYY08DD
 
Upvote 0
when I use this formula do you why I get YYYY08DD
You should get "20230815".

There is no way I can see the formula:
Excel Formula:
=TEXT(TODAY(),"YYYYMMDD")
returning:
Excel Formula:
YYYY08DD
unless you have some really bizarre regional settings.

Just to confirm, are you using Excel, or some other program?
 
Upvote 0
You could try switching to lower case and see if that makes a difference, i.e.
Excel Formula:
=TEXT(TODAY(),"yyyymmdd")
 
Upvote 0
You should get "20230815".

There is no way I can see the formula:
Excel Formula:
=TEXT(TODAY(),"YYYYMMDD")
returning:
Excel Formula:
YYYY08DD
unless you have some really bizarre regional settings.

Just to confirm, are you using Excel, or some other program?
Iam a german user
 
Upvote 0
What about all my other questions/suggestions?

1. Are you using Excel? If so, what version?

2. Did you try:
Excel Formula:
=TEXT(TODAY(),"yyyymmdd")

3. Do you use commas or semi-colons to separate formula arguments?
If semi-colons, you would need to change the formula, i.e.
Excel Formula:
=TEXT(TODAY();"yyyymmdd")

4. What do your date regional settings look like?
 
Upvote 0
You should get "20230815".

There is no way I can see the formula:
Excel Formula:
=TEXT(TODAY(),"YYYYMMDD")
returning:
Excel Formula:
YYYY08DD
unless you have some really bizarre regional settings.

Just to confirm, are you using Excel, or some other program?
Iam a german user
What about all my other questions/suggestions?

1. Are you using Excel? If so, what version?

2. Did you try:
Excel Formula:
=TEXT(TODAY(),"yyyymmdd")

3. Do you use commas or semi-colons to separate formula arguments?
If semi-colons, you would need to change the formula, i.e.
Excel Formula:
=TEXT(TODAY();"yyyymmdd")

4. What do your date regional settings look like?
1.Microsoft 365 for enterprise
2. Yes, the result is yyyy00dd
3. Semi -Colons which I actually used
 
Upvote 0

Forum statistics

Threads
1,215,555
Messages
6,125,490
Members
449,234
Latest member
slzaleski

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top