How to Change the SharePoint Date Format (Beginner’s Guide)

How to Change the SharePoint Date Format (Beginner’s Guide)

Last Updated on August 26, 2023

Do you want to change the date format in your SharePoint site?

In this short guide, you will learn more about the default date format in SharePoint and the exact steps to changing it from the settings.

Let’s get started.

The default date format in SharePoint Online

By default, SharePoint presents dates in the format mm/dd/yyyy (this is the US format).

However, depending on your location or your company’s preferences, this may not be the most intuitive or efficient way for you and your team to work with dates.

The issue with the default date format

One common issue that users run into with SharePoint’s default date format is its lack of flexibility.

While it works for some, there are many who prefer or are more familiar with different date formats, such as DD/MM/YYYY, often used in many countries outside the United States.

Others might prefer a more verbose format, like mmm dd, yyyy (e.g., Jan 01, 2023), especially when dealing with a non-technical audience.

Understanding the date format and its potential limitations is the first step toward tailoring your SharePoint Online experience to better suit your needs and preferences.

As you will see in the following section, changing this format is a straightforward process that can greatly enhance your productivity and ease of use within the platform.

Sign up for exclusive updates, tips, and strategies

    Changing the date format in SharePoint

    Changing the date format simply means changing the locale or country of your SharePoint site collection.

    This will affect the following date fields in SharePoint lists:

    • Create date column
    • Modified date column
    • Any custom date column

    Though it may not be that relevant today, subsites created in a site collection where you changed the regional settings will inherit those settings.

    Related: SharePoint Subsite vs Site: How They Differ From Each Other

    Step 1: Access SharePoint settings

    The first step here is to access the SharePoint Online settings page.

    Open your site and do the following:

    1. Click the gear icon
    2. Click site information
    SharePoint site information

    The right panel will then open.

    Click the view all site settings link:

    View all site settings button

    Step 2: Navigate to the regional settings

    The next step is to go to the regional settings of the site.

    Look for it under the site administration group:

    site administration to regional settings

    Step 3: Change the date format

    You will now see the different regional settings that you can change:

    • Time zone
    • Region

    The option here that will allow you to change the display dates format is the locale.

    Click the dropdown and choose your country or the country with the format that you want to use:

    change date format in sharepoint

    Right after that, all you need to do is click the ok button at the bottom to save the changes.

    For more information on the date formats per country, you can check here: Listing of countries with their preferred date formats.

    Alternative: Use PowerShell Scripts

    You can also use PowerShell scripts to change the date format in SharePoint Online in one site collection and for all sites in the tenant.

    You will need to know the locale ID of the country you want to use. You can refer here: Part 4 Section 7.6.2.39, LCID (Locale ID).

    For the script to change the locale date format, use this (credits here):

    #Load SharePoint CSOM Assemblies
    Add-Type -Path "C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.dll"
    Add-Type -Path "C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
      
    #Config parameters for SharePoint Online Site URL and Locale
    $SiteURL = "https://yoursite.sharepoint.com"
    $LocaleID ="4105" #English - Canada
      
    #Get Credentials to connect
    $Cred= Get-Credential
    $Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Cred.Username, $Cred.Password)
        
    #Set up the context
    $Ctx = New-Object Microsoft.SharePoint.Client.ClientContext($SiteUrl)
    $Ctx.Credentials = $credentials
     
    #Get Regional Settings of the Web
    $Web = $Ctx.Web
    $Ctx.Load($web)
    $Ctx.Load($Web.RegionalSettings)
    $ctx.ExecuteQuery()
      
    #Update the LocaleID of the site
    $Web.RegionalSettings.LocaleId = $LocaleID
    $Web.Update()
    $Ctx.ExecuteQuery() 

    For changing the format in all the sites in the tenant, use this:

    #Load SharePoint CSOM Assemblies
    Add-Type -Path "C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.dll"
    Add-Type -Path "C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
      
    #function to change Locale in regional settings of a SharePoint Online site
    Function Set-SPOLocale([String]$SiteURL,[String]$LocaleID, [PSCredential]$Cred)
    { 
         Try
         {
            #Set up the context
            $Ctx = New-Object Microsoft.SharePoint.Client.ClientContext($SiteURL)
            $Ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Cred.Username, $Cred.Password)
        
            #Get Regional Settings of the Web
            $Web = $Ctx.Web
            $Ctx.Load($web)
            $Ctx.Load($Web.RegionalSettings)
            $ctx.ExecuteQuery()
      
            #Update the LocaleID of the site
            $Web.RegionalSettings.LocaleId = $LocaleID
            $Web.Update()
            $Ctx.ExecuteQuery()
      
            Write-host -f Green "Locale has been updated for "$Web.Url
      
            #Get all subsites of the web
            $Ctx.Load($Web.Webs)
            $Ctx.executeQuery() 
            #Iterate through each subsites and call the function recursively
            Foreach ($Subweb in $Web.Webs)
            {
                #Call the function to set Locale for the web
                Set-SPOLocale -SiteURL $Subweb.URL -LocaleID $LocaleID -Cred $Cred
            }
        }
        Catch [System.Exception]
        {
            Write-Host -f Red "Error:"$_.Exception.Message
        }
    } 
      
    #Config parameters for SharePoint Online Admin Center and Locale description
    $AdminSiteURL = "https://tenant-admin.sharepoint.com"
    $LocaleID ="4105"
      
    #Get credentials to connect to the SharePoint Online Admin Center
    $Credentials = Get-Credential
      
    #Connect to SharePoint Online Tenant Admin
    Connect-SPOService -URL $AdminSiteURL -Credential $Credentials
      
    #Get all Site Collections and Iterate through
    Get-SPOSite -Limit ALL | ForEach-Object { 
        Set-SPOLocale -SiteURL $_.URL -LocaleID $LocaleID -Cred $Credentials
    }

    Verify the changes in the date format

    After you’ve made the necessary changes to your date format, it’s crucial to ensure that your changes have been applied successfully.

    Start by navigating to an item in your SharePoint list or library that contains a date field.

    • Is the date format now showing in the new style that you’ve selected?
    • If yes, congratulations! You have successfully changed your date format.

    Got any questions about the date format? If yes, kindly drop your comment or question below.

    For business-related questions, you can send me a direct message using the contact form on this page.

    About Ryan Clark

    As the Modern Workplace Architect at Mr. SharePoint, I help companies of all sizes better leverage Modern Workplace and Digital Process Automation investments. I am also a Microsoft Most Valuable Professional (MVP) for SharePoint and Microsoft 365.

    Subscribe
    Notify of
    guest
    3 Comments
    Oldest
    Newest Most Voted
    Inline Feedbacks
    View all comments

    Lahatra RAKOTONDRAMANITRA
    Lahatra RAKOTONDRAMANITRA
    1 year ago

    Hello
    can you help me ?
    it’s about to use DateDif in column that i need in a Calculated (calculation based on other columns)

    Renier
    Renier
    1 year ago

    This really helped me a lot. Thank you

    David Adams
    David Adams
    1 year ago

    Really good content for retroactively changing the date format, but is there a way to simply change the default? In SharePoint Admin > Settings > Site Creation, you can change the default timezone for subsequently created sites, is there something similar for region?

    3
    0
    Would love your thoughts, please comment.x
    ()
    x
    Scroll to Top