SharePoint Online: Change Header Layout, Site Logo, Background using PowerShell
Requirement: Change Header layout, Site Logo and Background settings in SharePoint Online.
How to Set Header layout, Site Logo and Background in SharePoint Online?
To change the header settings in SharePoint Online,
PowerShell to Set Header layout, Site Logo and Background:
Lets change the SharePoint Online header layout, header background color and header logo using PowerShell.
Please note, on group connected modern sites, changing the logo is bit different. Refer How to Change Site Logo in SharePoint Online?
How to Set Header layout, Site Logo and Background in SharePoint Online?
To change the header settings in SharePoint Online,
- Click on "Settings" gear icon >> Click on "Change the look" from site settings menu.
- Click on "Header"
- Set the header layout, site logo and header background.
- Click on "Save" to commit your changes.
PowerShell to Set Header layout, Site Logo and Background:
Lets change the SharePoint Online header layout, header background color and header logo using PowerShell.
#Set Variables $SiteURL = "https://crescent.sharepoint.com/sites/credit" $LogoURL= "https://crescent.sharepoint.com/sites/credit/SiteAssets/logo.jpg" #Connect to PNP Online Connect-PnPOnline -Url $SiteURL -UseWebLogin #Get the Web $Web = Get-PnPWeb #Set Header Options $Web.HeaderLayout = "Standard" # Standard, Compact $Web.HeaderEmphasis = "None" # None, Neutral, Soft, Strong $Web.SiteLogoUrl = $LogoURL $Web.Update() Invoke-PnPQuery
Please note, on group connected modern sites, changing the logo is bit different. Refer How to Change Site Logo in SharePoint Online?
No comments:
Please Login and comment to get your questions answered!