When you share files or folders from OneDrive for Business, the recipient gets a link. Over time, you may have shared dozens or hundreds of links. Finding every link you have ever created is not obvious from the OneDrive web interface. This article shows you how to locate all shared links using the OneDrive web app, the Microsoft 365 admin center, and PowerShell. You will also learn how to view who accessed each link and how to revoke links you no longer need.
Key Takeaways: How to Audit and Manage Shared Links in OneDrive for Business
- OneDrive web app > Shared > Links tab: Shows all active sharing links created by you and others in your organization for your files.
- Microsoft 365 admin center > Reports > Usage > OneDrive > Sharing: Generates a CSV report of all shared files and links across your tenant.
- SharePoint Online Management Shell > Get-SPOSiteGroup: PowerShell cmdlet to export all sharing links for a specific OneDrive site.
Understanding Where OneDrive Stores Shared Links
OneDrive for Business stores sharing links as part of the file or folder metadata. When you share a file, OneDrive creates a unique URL called a sharing link. This link can be an anonymous guest link, a link that requires sign-in, or a link restricted to specific people. The link itself is not a separate object in your OneDrive. Instead, it is attached to the file or folder in the site permissions.
The OneDrive web app provides a centralized view of all your shared items. This view includes files you have shared and files shared with you. However, the default view does not always list every link you have ever created. Some links may be expired, revoked, or created through the Microsoft 365 sharing interface. To get a complete list, you need to combine the web interface with administrative reports or PowerShell commands.
What Types of Sharing Links Exist
OneDrive for Business supports three main link types:
- Anyone links: Provide access to anyone who receives the link. No sign-in required.
- People in your organization links: Require the recipient to sign in with a work or school account in the same tenant.
- Specific people links: Restricted to a list of email addresses. Recipients must sign in to access.
Each link type appears differently in the shared-by-you view. Expired links disappear from the default list after 30 days. Revoked links are removed immediately.
Steps to View All Shared Links From the OneDrive Web App
The quickest way to see your shared links is through the OneDrive web app. Follow these steps to access the full list.
- Open OneDrive in your browser
Go tohttps://onedrive.live.comand sign in with your work or school account. If you are redirected, ensure you are on the OneDrive for Business tenant. - Navigate to the Shared section
In the left navigation pane, click Shared. The page shows two tabs: Shared by you and Shared with you. The Shared by you tab lists all files and folders you have shared, along with the sharing link type. - Filter by link type
Click the Shared by you tab. Use the filter dropdown to select Links. This filter shows only items that have active sharing links. Items shared directly with people via email invitations are not shown here. - Review the list of shared items
Each row shows the file or folder name, the link type, the date the link was created, and the expiration date if one is set. Click on any item to see the specific link URL. You can copy or revoke the link from this view. - Export the list (optional)
There is no built-in export button. To save the list, copy the rows manually or use the browser print function to save as PDF.
What the Web View Does Not Show
The Shared by you tab only shows links that are currently active. It does not show:
- Links that have expired
- Links that you revoked
- Links created by other users on your files if they have edit permissions
- Links created through the Microsoft 365 admin center or SharePoint
For a complete audit, use the Microsoft 365 admin center report or PowerShell.
Using the Microsoft 365 Admin Center to Find All Shared Links
Global administrators or SharePoint administrators can generate a sharing report for all OneDrive sites in the tenant. This report includes every sharing link created by any user.
- Sign in to the Microsoft 365 admin center
Go tohttps://admin.microsoft.comand sign in with an account that has Global admin or SharePoint admin role. - Open the Reports section
In the left navigation, expand Reports and click Usage. - Select OneDrive from the report list
Click OneDrive. The report shows storage, active users, and sharing activity. - View the Sharing report
Scroll down to the Sharing section. Click View details. This shows the number of files shared externally and internally. - Download the detailed CSV
Click Export to download a CSV file. The CSV contains one row per shared file or folder. Columns include the site URL, the file path, the link type, and the user who shared it. - Filter the CSV for your OneDrive site
Open the CSV in Excel. Filter the Site URL column to show only your OneDrive site URL, which follows the patternhttps://yourtenant-my.sharepoint.com/personal/youralias_yourdomain_com.
This report includes all active links at the time of export. It does not include expired or revoked links.
Using PowerShell to Export All OneDrive Sharing Links
PowerShell gives you the most control. You can retrieve sharing links for a specific OneDrive site, including links that are about to expire. You need the SharePoint Online Management Shell.
- Install the SharePoint Online Management Shell
Open PowerShell as administrator and runInstall-Module -Name Microsoft.Online.SharePoint.PowerShell. Confirm the installation. - Connect to SharePoint Online
RunConnect-SPOService -Url https://yourtenant-admin.sharepoint.com. Enter your admin credentials. - Get your OneDrive site URL
RunGet-SPOSite -IncludePersonalSite $true -Limit all | Where-Object {$_.Url -like "/personal/youralias"} | Select-Object Url. Replaceyouraliaswith your email alias. - Export sharing links for your site
Run the following command to export all sharing links to a CSV file:Get-SPOSiteGroup -Site https://yourtenant-my.sharepoint.com/personal/youralias_yourdomain_com | Select-Object -ExpandProperty Users | Export-Csv -Path C:\temp\sharinglinks.csv -NoTypeInformation
This exports all users and their permission levels. To see only sharing links, you need to parse theTitleandLoginNamefields. - Use a more detailed script
For a complete list of sharing links, use theGet-PnPSharingLinkcmdlet from the PnP PowerShell module. Install it withInstall-Module PnP.PowerShell. Then run:Connect-PnPOnline -Url https://yourtenant-my.sharepoint.com/personal/youralias_yourdomain_com -Interactive
Get-PnPSharingLink | Export-Csv -Path C:\temp\allsharinglinks.csv -NoTypeInformation
The CSV from Get-PnPSharingLink includes the link URL, the type, the expiration date, and the file or folder path.
Common Issues When Finding Shared Links
The Shared by You Tab Shows No Links
If the Shared by you tab is empty, you may have filtered incorrectly. Ensure the filter is set to Links and not People. Also check that you have not revoked all links. If you share files only through direct email invitations without creating a link, they will not appear in the Links filter.
The Admin Report Does Not Include My OneDrive Site
The Microsoft 365 admin center report includes all OneDrive sites by default. If your site is missing, verify that your OneDrive is provisioned. Go to https://yourtenant-my.sharepoint.com and sign in. If you see your files, the site exists. The report may take up to 48 hours to reflect new sharing activity.
PowerShell Returns No Results
The Get-PnPSharingLink cmdlet requires the PnP PowerShell module. If you get an error, run Update-Module PnP.PowerShell. Also ensure you are connected to the correct site URL. The URL must end with your personal site path, not the admin URL.
OneDrive Web App vs Admin Report vs PowerShell: Key Differences
| Item | OneDrive Web App (Shared tab) | Microsoft 365 Admin Report | PowerShell (Get-PnPSharingLink) |
|---|---|---|---|
| Scope | Current user only | All users in tenant | Single site or all sites |
| Link types included | Active links only | Active links only | Active and expiring links |
| Expired links shown | No | No | No |
| Export format | Manual copy or PDF | CSV | CSV |
| Requires admin rights | No | Yes | Yes |
| Shows link URL | Yes, per item | No | Yes |
For most users, the OneDrive web app Shared tab is sufficient. For admins who need to audit all links across the tenant, the admin report or PowerShell is necessary.
You can now find every link shared from your OneDrive account using the Shared tab in the OneDrive web app. For a tenant-wide audit, use the Microsoft 365 admin center sharing report or the Get-PnPSharingLink PowerShell cmdlet. After you locate links you no longer need, revoke them directly from the Shared tab by clicking the three dots next to the item and selecting Manage access. As a best practice, set expiration dates on all new Anyone links to prevent forgotten shares from persisting indefinitely.