Change the SharePoint domain name in your Microsoft 365 Tenant


Back when all the Cloud and SaaS offerings where a brand new concept most IT administrators ended up choosing the domain name of a tenant. This choice would be then reflected in the SharePoint Online url and the only way to change it was to create brand new tenant. Either due to the somewhat poor choice from the IT administrators, due to mergers, rebranding or acquisitions some organization ended up with lets say less desirable domain name for their SharePoint URL.
Responding to clients with a “no it is not possible to change that” always bothered me back then. So when I learned that this option is now available (in preview) I immediately decided to try it. Via this post I want to share what I learned testing this option.

Please make sure to read the official documentation for limitations of this option and the fact that this is till in preview at the time of writing this post before even considering it in production.
Having said that, lets go!

  1. Start by navigating to . Make sure to use this URL. If you decide to navigate without the use of this URL the rename will not work.
  2. Click on Add a custom domain button at the top, then fill in the desired domain name including the suffix. As shown in the following image I want to rename my tenant from 2tkc6c to demojev there fore I used
If you have to try and figure out if certain domains might be available you can just enter those domains in your browser using this format https://[YOUR_DOMAIN_NAME]
Domain name added page with warning
  1. Click on the Add domain button at the bottom right corner. If the domain is available you will get a message Domain name added and will be redirected to screen show in the following image.
Do not add any other domains and make sure you did not get a prompt create a new TXT record with your domain name registrar. Because if you did the domain name has not been added correctly and it will not be elegible for a rename. If you get this prompt you need to delete the newly added domain and recreate it again starting from step 1.
Add a custom domain name page
  1. As show in the following image use the top navigation breadcrumb to go back to the custom domain names.
Breadcrumb, use it to go back
  1. Ensure that the newly added domain name is verified. This is shown in the following image.
New domain name is verified

For continuing with the next steps the latest version of the SharePoint Online Management Shell is required. Make sure to have it installed.

Install SharePoint Online Management Shell
  1. Open a PowerShell 5.1 window and connect using the newly downloaded and installed SharePoint Management Shell by using the Connect-SPOService command using your current SharePoint domain. Depicted from my own rename in the following PowerShell snippet.
  1. A log-in prompt will be shown, use a Global Administrator account to complete this log-in. As again shown in the following image.
Log-in prompt
  1. The last remaining step is to queue the rename. Since the rename must take place at least 24h in the future I decided to add a timespan of 24 hours and 10 minutes to the current date & time. The combined commands are shown in the following PowerShell snippet.

Example of the script outputs:

Check rename status script output

The command returns a RenameJobID but at this moment this ID cannot be used as input anywhere. The documentation states that the status of the rename can be acquired through the command Get-SPOTenantRenameStatus. However since it’s still in preview the following note is stated when navigating to the documentation:

This feature is in preview and currently available to organizations that have no more than 1,000 total SharePoint sites and OneDrive accounts combined.

Fast forward 24 hours and 10 minutes and the results of the rename should visible.

Successful domain rename rename

And that is it. Thanks for reading this post and if you liked it don’t be shy and have a look at my other posts .