Formatting Issues

How to Stop Excel from Changing Entered Dates and Ignoring Leading Zeros

Emma BrownEmma Brown Nov 2, 2026 869 views

Question details

The user wants to stop Excel from improperly treating six-digit date entries (such as 110121) as standard numbers and discarding their leading zeros.

How to Stop Excel from Changing Entered Dates and Ignoring Leading Zeros
Product
Microsoft Excel
Device & OS
not provided
Scenario
Entering dates in a compact six-digit format to save time during manual data entry.
Observed behavior
Excel interprets the six-digit string as a standard numeric value, dropping any leading zeros and failing to recognize it as a valid date serial number.
Before you start

Determine whether you need the entered data to function as real dates for chronological sorting and calculations, or if you simply need them to visually display as text with leading zeros intact.

Solution 1Recommended

Apply an Unambiguous Custom Date Format

Use Excel's custom formatting options to force dates to display clearly, preventing regional setting confusion and standardizing appearance.

Excel handles dates as serial numbers based on your system's regional settings. Applying a custom date format ensures that dates are displayed consistently, regardless of the computer viewing the file.

1
Select the target cells

Highlight the cells or entire column where you plan to enter or display your dates.

2
Open Format Cells

Right-click the highlighted area and choose 'Format Cells' from the context menu, or press Ctrl+1 on your keyboard.

3
Set the Custom Format

Navigate to the 'Number' tab, select 'Custom' from the category list on the left, and type 'dd-mmm-yyyy' (e.g., 11-Jan-2021) or 'dd/mm/yy' in the Type box. Click OK.

Apply an Unambiguous Custom Date Format
Tip: Using a format with letters for the month (like 'mmm') completely eliminates the ambiguity between US (mm/dd) and UK (dd/mm) date formats.

Easily Control Date Formats with WPS Spreadsheet

WPS Spreadsheet provides robust, intuitive cell formatting tools that give you full control over how dates and numbers with leading zeros are displayed, ensuring accurate data entry every time.

  1. 1. Open your file in WPS Spreadsheet: Launch WPS Office and open your existing spreadsheet or create a new blank document.
  2. 2. Select the cells to format: Highlight the specific columns or cells where your dates will be entered.
  3. 3. Access cell formatting: Right-click the selected range and click on 'Format Cells' to open the formatting dialog box.
  4. 4. Apply a custom date format: Under the Number tab, select 'Custom', input a clear date format like 'dd/mm/yyyy' or 'dd-mmm-yyyy', and click OK to apply.
Free and lightweight spreadsheet softwareFully compatible with Microsoft Excel (.xlsx) formatsIntuitive custom cell formatting for accurate date displayAdvanced data validation to prevent entry errors
microsoft office alternative - wps office

Frequently Asked Questions

Why does Excel automatically remove the leading zero from my date entries?

Excel automatically interprets strings of digits as standard numerical values. Because leading zeros do not add mathematical value to whole numbers, Excel removes them by default unless the cell is specifically pre-formatted as Text.

Can I automatically convert a 6-digit number like 110121 to a real date?

Excel does not natively convert a continuous string of six digits into a date just by typing it. To convert existing six-digit numbers, you can use the 'Text to Columns' feature under the Data tab and set the column data format to Date, or use a custom VBA macro to parse the digits.

How do I stop dates from changing format when opening my file on another computer?

Date displays can swap between DD/MM and MM/DD based on the local computer's Windows regional settings. To prevent this, apply a custom format like 'dd-mmm-yyyy' (which displays as 11-Jan-2021) so the date remains unambiguous across all regions.