When your IT team migrates a department to a new SharePoint site, OneDrive for Business may show a shared library sync status of “Pending” indefinitely. This happens because the sync client holds a reference to the old library URL and cannot locate the migrated content. The migration changes the underlying SharePoint site ID, which breaks the existing sync relationship. This article explains why the sync stays pending during a department migration and provides the specific steps to resolve the issue without losing local files.
Key Takeaways: Fix Pending Sync After a SharePoint Library Migration
- Stop sync for the old library via OneDrive Settings > Account > Stop sync: Removes the broken link to the pre-migration SharePoint site.
- Sync the new library URL from the SharePoint Online site: Re-establishes a valid sync relationship with the migrated library.
- Use the Known Folder Move policy if migration affects user profile folders: Prevents pending status for Desktop, Documents, and Pictures after a site move.
Why OneDrive Sync Stays Pending After a Department Migration
OneDrive for Business syncs shared libraries by storing the SharePoint site ID, library GUID, and server-relative URL in a hidden local database. When IT migrates a department to a new SharePoint site, the site ID changes even if the library name stays the same. The sync client sees the old site ID and cannot match it to any library on the server. It displays “Pending” because it is waiting for the old relationship to become valid again.
The sync engine does not automatically detect a site migration. It does not poll SharePoint for site ID changes. It holds the old sync relationship until the user manually stops it. The pending status is not a network or credential problem. It is a stale association between the local sync folder and a SharePoint site that no longer exists at the stored URL.
How SharePoint Site ID Changes During Migration
When an administrator moves a site collection to a different geography or content database, SharePoint Online assigns a new site ID. The library URL may remain the same, but the underlying unique identifier changes. OneDrive for Business relies on the site ID, not the URL, to maintain sync. After migration, the stored site ID no longer matches, so the client shows pending instead of syncing.
Why Resyncing the Same URL Does Not Fix It
Clicking the Sync button on the same library URL after migration creates a new sync relationship. But the old pending relationship still exists in the sync client. OneDrive cannot have two sync relationships for the same library. The old pending one blocks the new one. You must remove the stale relationship before adding the new one.
Steps to Clear Pending Sync and Reconnect to the Migrated Library
- Open OneDrive Settings
Right-click the OneDrive cloud icon in the system tray near the clock. Select Settings from the menu. If you do not see the icon, click the Show hidden icons arrow and then right-click the OneDrive cloud. - Go to the Account tab
In the OneDrive settings window, click the Account tab at the top. This tab shows all syncing libraries under your work or school account. - Identify the pending library
Look for the shared library that shows a status of “Pending” or “Not syncing.” The library name is the one that was migrated. It may show the old SharePoint site name. - Stop sync for the pending library
Click the three dots (More menu) next to the library name. Select Stop sync. A confirmation dialog appears. Click Stop sync again to confirm. This removes the stale sync relationship and deletes the local shortcut. Your files remain in the local OneDrive folder until you choose to delete them. - Navigate to the new SharePoint site in a browser
Open Microsoft Edge, Chrome, or any browser. Go to the new SharePoint site URL provided by your IT team. Sign in with your work or school account if prompted. - Open the document library
On the SharePoint site, click Documents in the left navigation or select the specific library name from the site contents. The library should contain the migrated files. - Click the Sync button
In the library toolbar, click the Sync button. A browser prompt may ask for permission to open OneDrive. Click Open OneDrive or Allow. OneDrive for Business opens and starts adding the new sync relationship. - Choose the sync folder location
OneDrive shows a dialog asking where to sync the files. The default path is under your OneDrive folder in a subfolder named after the site. Click Sync now. The library begins syncing immediately. The pending status is gone.
If OneDrive Still Shows Pending After Resyncing
OneDrive Shows Multiple Pending Libraries for the Same Site
If your IT team migrated the site more than once, you may see several pending entries for the same library. Each migration creates a new pending relationship. Stop sync for each one individually. There is no bulk remove option. After removing all stale entries, sync the current library URL once.
Stop Sync Option Is Grayed Out
If the Stop sync button is disabled, the sync client is in a corrupted state. Close OneDrive completely. Press Ctrl+Alt+Delete and open Task Manager. End the OneDrive.exe process. Restart OneDrive from the Start menu. Then try stopping sync again. If the button remains gray, reset OneDrive by running the command onedrive.exe /reset from the Run dialog Win+R.
Local Files Were Deleted After Stopping Sync
When you stop sync, OneDrive asks if you want to keep the local copies. If you selected “Delete files from this device,” the local copies are moved to the recycle bin. Restore them from the recycle bin before syncing the new library. After restoring, place the files in the new sync folder location. OneDrive will compare them with the server version.
IT Migrated Known Folder Move Locations
If your IT team migrated the SharePoint site that stores Desktop, Documents, or Pictures via Known Folder Move, the pending status affects those folders too. After stopping sync for the old library, go to OneDrive Settings > Sync and backup > Manage backup. Click Stop backup for each folder. Then click Start backup and select the new site library. This reconnects the folders to the migrated location.
Stop Sync vs Unlink This PC vs Reset OneDrive: Key Differences
| Item | Stop Sync | Unlink This PC | Reset OneDrive |
|---|---|---|---|
| Effect on pending libraries | Removes only the selected library sync | Removes all sync relationships for the account | Clears all local sync metadata and reinitializes the client |
| Local files kept | Yes, if you choose Keep files | Yes, files stay in the OneDrive folder | No, the local OneDrive folder is recreated |
| When to use | Single library pending after migration | Multiple libraries pending or account-level corruption | Client crashes, persistent errors, or after unlink fails |
Use Stop sync for a single migrated library. Use Unlink This PC when multiple libraries show pending. Use Reset OneDrive only as a last resort because it requires a full resync of all libraries.
After stopping sync and resyncing the new library, OneDrive for Business syncs the migrated content without a pending status. The stale site ID is removed, and the new site ID is stored. If the pending status returns, check with your IT team that the migration is fully complete and that the new site URL is accessible from your account. For large libraries with more than 100,000 files, sync may take several hours to show all items. You can monitor progress by clicking the OneDrive cloud icon and selecting View sync activity.