top of page
Writer's pictureSubir Hazra

How to Change the SharePoint Welcome Page: Step-by-Step Guide for SharePoint Site and PowerShell

To change the welcome page in SharePoint, you can follow these steps:

  1. Navigate to your SharePoint site as a site administrator

  2. Click on the gear icon in the top-right corner to access the Site Settings

  3. In the Site Settings page, under the "Look and Feel" section, click on "Welcome page" or "Welcome page under "Look and Feel" or directly browse the below URL, https://Sharepoint-site-URL/_layouts/AreaWelcomePage.asp

  4. On the Welcome Page settings page, select the desired welcome page from the list of available pages or specify a custom URL

  5. Click "OK" or "Save" to apply the changes


SharePoint Welcome Page Button
SharePoint Welcome Page Button

By default, SharePoint uses the "Home.aspx" page as the welcome page. However, you can select any other page within your site or even specify a custom URL to set as the welcome page.


Note that you need to have sufficient permissions as a site administrator or owner to access and modify the site settings.

Change SharePoint Welcome Page using PowerShell


To set the welcome page in SharePoint using PowerShell, you can use the following code:


$SiteUrl = "https://sharepoint.com"
$Site = Get-SPWeb -Identity $SiteUrl
$RootFolder = $Site.RootFolder
$RootFolder.WelcomePage = "SitePages/HomePage.aspx"
$RootFolder.Update()
$Site.Dispose()

This code assumes that you have the SharePoint PowerShell module installed and have appropriate administrative privileges.


Here's a breakdown of what the code does:


1. Set the variable `$SiteUrl` to the URL of your SharePoint site.

2. Use the `Get-SPWeb` cmdlet to retrieve the SharePoint site object based on the given URL.

3. Get the root folder of the site using `$Site.RootFolder`.

4. Set the `WelcomePage` property of the root folder to the desired welcome page URL (e.g., "SitePages/HomePage.aspx").

5. Update the root folder to save the changes using `$RootFolder.Update()`.

6. Dispose of the SharePoint site object using `$Site.Dispose()` to release the resources.


By executing this PowerShell script, you can programmatically set the welcome page for your SharePoint site without modifying the provided code.

Yorumlar


Disclaimer

Welcome to my professional blog! The articles shared here are based on my personal experiences and knowledge, intended to serve as a valuable reference for myself and to assist readers like you.

 

Kindly refrain from reproducing my content in any manner without obtaining my explicit permission. In the event that any article infringes upon copyright regulations, please don't hesitate to reach out to me. I appreciate your input and encourage you to share your insights or alternative solutions by leaving a comment. Your valuable contributions are highly appreciated!

Copyright © 2023 by SHAREPOINT INSIGHTS. All rights reserved.

bottom of page