Forum Discussion

george2275's avatar
george2275
Copper Contributor
Jul 21, 2023

Finding SharePoint Online Links - Possible?

Hi All - I'm trying to find all links (anywhere in SharePoint) to a page on SharePoint Online? Is this possible? I am not finding any solutions that don't involve 3rd party tools.

2 Replies

  • LeonPavesic's avatar
    LeonPavesic
    Silver Contributor

    Hi george2275,

    It is possible to find all links to a specific page in SharePoint Online with PowerShell:

    # Parameters
    $AdminSiteURL = "https://yourdomain-admin.sharepoint.com"
    $SiteURL = "https://yoursite.sharepoint.com/sites/marketing"
    
    # Connect to SharePoint Online from PowerShell
    Connect-SPOService -url $AdminSiteURL
    
    # Get the Site Collection
    $Site = Get-SPOSite -Identity $SiteURL
    
    # SharePoint Online list all site collections powershell
    $Site | Select -Property Url, Template, StorageUsageCurrent, StorageQuota, LastContentModifiedDate, sharingcapability


    To succesfully run this script you need to install SharePoint Online Management Shell (Download SharePoint Online Management Shell from Official Microsoft Download Center) and open the SharePoint Online Management Shell as an Administrator.

    As an input you need to insert your Sharepoint admin page URL and the URL from the site you want to export the link properties. Then you need to connect (log in) to SharePoint Online after you run the script. You will have the results in C:\Temp\SharedLinks.csv file.

    Please click Mark as Best Response & Like if my post helped you to solve your issue.
    This will help others to find the correct solution easily. It also closes the item.


    If the post was useful in other ways, please consider giving it Like.


    Kindest regards,


    Leon Pavesic

    • george2275's avatar
      george2275
      Copper Contributor
      I don't think I explained it very well. I have a sharepoint page and I want to know all places where it has a link to that specific page, that script doesn't appear to do that. Thanks

Resources