SharePoint Online: How to Change the Site Title (Name) using PowerShell?
Requirement: Change the Site Title in SharePoint Online.
SharePoint Online: How to Change the Name of a Site?
Whether you’re looking to rebrand your site, reorganize your content, or make your site’s purpose clearer to your users, changing the name of your SharePoint site is a crucial task that every administrator should know. This blog post will walk you through how to change the name of a SharePoint site in Office 365 quickly and easily!
How to change the name of a SharePoint Online site? Well, To change the site collection title in SharePoint Online, follow these steps:
- Login to your SharePoint site >> Go to the Site Settings Page >> Click on the “Title, Description, and Logo” link under “Look and Feel”.
- Enter the new title for your site or site collection.
- Click “OK” to save your changes. That’s it! This changes the site name. Your new site name will be displayed on the home page and in browser tabs. Now, let’s use PowerShell to change the site name in SharePoint Online.
How to Change Site Name in Modern SharePoint Online Sites?
Site names are given at the time of creating site collections or subsites. However, If you want to change the site name, follow the below steps:
- Login to the site where you would like to change the name.
- Click on Settings gear >> Click on the “Site Information” link.
- Enter the Site name value and hit Save to change the name to your SharePoint site.
In the “Site Information” panel, you can also update the Site description and click on the “Save” button.
Once you’ve successfully renamed your SharePoint site, it’s crucial to communicate the change to your team! Email your team to announce the new site name and explain the reason for the change.
Also, if your site is part of the global navigation, it’s important to update your navigation to reflect the change after changing your site name.
How do you change the SharePoint site name through the Admin Center?
To change the SharePoint site name through the admin center, follow these steps:
- Sign in to the SharePoint admin center.
- Click on the Sites >> Active sites in the left-hand navigation pane.
- Select the desired site from the list >> Click on the “Edit” button next to the site info.
- Enter the new name for the site and click “Save”.
Browse to the site to see the renamed site in action! Please note that changing the site name will not affect the SharePoint URL of the site.
PowerShell to Change Site Title in SharePoint Online:
Let’s see the PowerShell script to change the SharePoint Online site name. Here is the PowerShell to change the site or site collection title in SharePoint Online.
#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"
#Variables
$SiteURL="https://Crescent.sharepoint.com/us"
$NewSiteTitle="United States"
$NewSiteDescription = "US Team Site"
Try {
$Cred= Get-Credential
$Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Cred.Username, $Cred.Password)
#Setup the context
$Ctx = New-Object Microsoft.SharePoint.Client.ClientContext($SiteURL)
$Ctx.Credentials = $Credentials
#Get the Site from URL
$Web = $Ctx.web
$Ctx.Load($web)
$Ctx.ExecuteQuery()
#Get the current site title
Write-host "Site Title:"$web.title
#sharepoint online powershell change site title
$web.title = $NewSiteTitle
#change sharepoint online site description
$web.description = $NewSiteDescription
$Web.Update()
$Ctx.ExecuteQuery()
Write-host "Site Title and Description has been updated!" -ForegroundColor Green
}
Catch {
write-host -f Red "Error Updating Site Title!" $_.Exception.Message
}
This PowerShell changes the site collection name and description to a new name.
SharePoint Online: Change Site Name using PnP PowerShell
Use the PnP PowerShell’s Set-PnPWeb cmdlet to change the site name in SharePoint Online:
#Config Variables
$SiteURL = "https://Crescent.sharepoint.com/Sales"
#Connect to PnP Online
Connect-PnPOnline -Url $SiteURL -Credentials (Get-Credential)
#sharepoint online powershell change site name
Set-PnPWeb -Title "Sales Portal"
Change SharePoint Online site description using PowerShell
Similarly, you can update the site’s description using the “-Description” parameter.
Set-PnPWeb -Description "Marketing Portal"
Wrapping up
Whether you’re rebranding your company in a merger or acquisition, restructuring your departments, or simply looking to improve your site’s clarity and organization, renaming a SharePoint site is a crucial task that every administrator should know how to handle.
By following this step-by-step guide and keeping the tips and troubleshooting advice in mind, you’ll be well-equipped to handle any site renaming challenges that come your way. Remember, a well-organized and clearly named SharePoint site is the foundation for effective collaboration and productivity within your organization.
To change the site URL (site address) in SharePoint Online, You can use the SharePoint Online Management Shell or PnP PowerShell! Refer: How to change the Site URL in SharePoint Online?
Hello! Any idea how to change the site name at Sharepoint Portal? I changed my site name at settings, it is showing the correct name on site menu, but it didn’t change on Sharepoint Portal!
Hi Salaudeen,
I’ve used your PNP code for modern Team site. Works great. I have an issue, that after a period of time the site reverts back to the old name. Any ideas? do i need to change the Active Directory Group name? Perhaps there’s a routine running that resets it back to the group / Exchange / Teams group name? Many thanks for you great site!!! cheers Ronan
That’s right! Renaming a Microsoft Team or Microsoft 365 group also renames the associated SharePoint site!