Is it possible to change the web address of a document library in Sharepoint?

Technician123 111 Reputation points
2022-05-11T20:38:28.577+00:00

201176-image.png

Microsoft 365 and Office | SharePoint | For business | Windows
0 comments No comments

Answer accepted by question author
Yi Lu_MSFT 17,701 Reputation points
2022-05-12T02:11:10.907+00:00

Hi @Technician123
Yes, we could change the url using SharePoint Designer: Open site > All files > select the document library and rename it

201262-image.png

As a result, the url has been changed from https://domain.sharepoint.com/sites/luyitest1311/doc/Forms/AllItems.aspx to https://domain.sharepoint.com/sites/luyitest1311/doc111/Forms/AllItems.aspx

201226-image.png

You could also change the library url using pnp (This code change the url from "https://domain.sharepoint.com/sites/luyitest1311/doc222" to "https://domain.sharepoint.com/sites/luyitest1311/doc333"

#Set Parameters  
$SiteURL = "https://domain.sharepoint.com/sites/luyitest1311/"  
$ListName = "doc222"  
$NewListURL = "doc333"  
    
#Connect to PnP Online  
Connect-PnPOnline -Url $SiteURL   
   
#Get the List  
$List= Get-PnPList -Identity $ListName -Includes RootFolder  
   
#sharepoint online powershell change list url  
$List.Rootfolder.MoveTo($NewListURL)  
Invoke-PnPQuery  

If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

Was this answer helpful?

3 people found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Technician123 111 Reputation points
    2022-06-06T15:21:17.307+00:00

    We ended up going with creating a new site and copying over all the contents. I don't believe the admins on our end use Sharepoint Designer or the PNP method. If this does come up again will run through that to test.

    Thank you!

    Was this answer helpful?

    1 person found this answer helpful.
    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.