Formatting Issues

Combine Birth Date Columns as YYYY-MM-DD in Excel

Bushra ParveenBushra Parveen Nov 18, 2026 872 views

Question details

Combine separate year, month, and day cells into a birth date displayed as YYYY-MM-DD, including leading zeros.

Product
Microsoft Excel
Device & OS
not provided
Scenario
A spreadsheet contains birth date components in separate columns that need to be combined.
Observed behavior
Concatenating the cells does not retain displayed leading zeros in the month and day.
Before you start

Check which columns contain the year, month, and day. The examples below assume they are in A2, B2, and C2, respectively; adjust the cell references if needed.

Solution 1Recommended

Create a real date and apply a custom format

Use this method when you want a date value that can still be sorted and used in calculations.

1
Enter the DATE formula

Select an empty cell such as D2 and enter =DATE(A2,B2,C2). Press Enter.

2
Open Format Cells

Select D2, right-click it, and choose Format Cells.

3
Set the date format

On the Number tab, select Custom, enter yyyy-mm-dd in the Type field, and click OK.

4
Fill the remaining rows

Drag the fill handle at the bottom-right corner of D2 down the column to apply the formula and formatting to the other rows.

Formatting changes the display: The result remains a date value; the custom format displays single-digit months and days with leading zeros.
Work with dates in WPS Spreadsheets

Combine and format birth dates in WPS Spreadsheets

Use the DATE formula and a custom number format in WPS Spreadsheets to combine year, month, and day columns while keeping the result as a date.

  1. 1. Open the spreadsheet: Open WPS Spreadsheets and select File > Open to load the workbook.
  2. 2. Combine the date components: In an empty cell such as D2, enter =DATE(A2,B2,C2), adjusting the references to match your year, month, and day columns.
  3. 3. Apply the custom format: Right-click the result cell, choose Format Cells, and select Custom. Enter yyyy-mm-dd as the format and click OK.
  4. 4. Fill the column: Drag the fill handle from the result cell down to the other rows.
Display birth dates as YYYY-MM-DD with leading zerosKeep dates available for sorting and calculationsOpen and edit Microsoft Excel XLSX and XLS filesUse a familiar spreadsheet interface
QA img-9

Frequently Asked Questions

Why do leading zeros disappear when I concatenate date cells?

A cell's displayed leading zero can come from its number format rather than its underlying value. Concatenation uses the value, so use =DATE(A2,B2,C2) and apply the custom format yyyy-mm-dd instead.

Will the DATE formula produce a value I can use in calculations?

Yes. =DATE(A2,B2,C2) produces a date value. Applying yyyy-mm-dd through Format Cells changes its display, not the underlying value.

How can I make the combined date text instead?

Enter =TEXT(DATE(A2,B2,C2),"yyyy-mm-dd") in an empty cell. The result is text rather than a date value.

What if my year, month, and day are in different columns?

Replace A2, B2, and C2 in the DATE formula with the cells containing the year, month, and day, in that order.