For example, you might have text values like this: When Excel has evaluated a date value as text, one option is to use a formula to parse the text into its components (year, month, day) and use these to make a date with the DATE function. Note you may need to apply date number formatting to display the date correctly. You can use the following formula to convert a date to a YYYYMMDD format in Excel: =TEXT (A1, "YYYYMMDD") This will convert a date such as 1/4/2022 to a format of 20220104. Excel can only recognize and convert dates that begin from 1 Jan 1900. First, select the range of cells B5:B10. Yes, you can write a VBA macro to automate the conversion of date values to text. In the Type box, make the necessary changes to the format. Excel starts counting from 1 instead of 0. Then copy the formula, select the cells that contain the text dates, and use Paste Special to apply a date format to them. Save my name, email, and website in this browser for the next time I comment. Making statements based on opinion; back them up with references or personal experience. How to Use Cron With Your Docker Containers, How to Use Docker to Containerize PHP and Apache, How to Pass Environment Variables to Docker Containers, How to Check If Your Server Is Vulnerable to the log4j Java Exploit (Log4Shell), How to Use State in Functional React Components, How to Restart Kubernetes Pods With Kubectl, How to Find Your Apache Configuration Folder, How to Assign a Static IP to a Docker Container, How to Get Started With Portainer, a Web UI for Docker, How to Configure Cache-Control Headers in NGINX, How to Set Variables In Your GitLab CI Pipelines, How to Use an NVIDIA GPU with Docker Containers, How Does Git Reset Actually Work? RELATED: How to Add or Subtract Dates in Microsoft Excel. Custom number formatting can also be used to convert date values to text. Unexpected uint64 behaviour 0xFFFF'FFFF'FFFF'FFFF - 1 = 0? But there may be situations where dates are in General or Text format. Converting Text to numbers - Microsoft Community Hub In the Type option, you will see different types of date formats. Click on the expand arrow. Now, Right-click the selection, click on the Paste Special. The general format in Excel starts counting the days from the date 1900-1-1. Excel functions, formula, charts, formatting creating excel dashboard & others. In your Excel worksheet, select a column of text entries you want to convert to dates.