In this article we will look at how to change the root site of your SharePoint online tenant.
Introduction
By default your SharePoint Online default site is unlikely to be the site you want users to go to.
Invoke-SPOSiteSwap
Using the Invoke-SPOSiteSwap command inside of the SharePoint Online Management Shell we are able ot change the root site.
Download and install the management shell
And then use your version of the following script to change your tenant root site. You will have to have admin access to the tenant to be able to do this
$targetSite = “https://yourTenant.sharepoint.com”
$soureSite = “https://yourTenant.sharepoint.com/sites/yourSite”
$archiveSite = “https://yourTenant.sharepoint.com/sites/archivedRoot”
Connect-SPOService -Url https://yourTenant-admin.sharepoint.com
Invoke-SPOSiteSwap -SourceUrl $soureSite -TargetUrl $targetSite -ArchiveUrl $archiveSite