How to Fix OneDrive Desktop Sign-In Error AADSTS50020
Question details
The user is unable to sign into the OneDrive desktop application due to error code AADSTS50020, even though OneDrive is accessible via a web browser and other Microsoft Office apps function properly.

- Product
- Microsoft OneDrive
- Device & OS
- Windows
- Scenario
- Attempting to link or log into a Microsoft account on the OneDrive desktop client.
- Observed behavior
- The sign-in process fails exclusively on the OneDrive desktop app returning error AADSTS50020, while web access and other desktop Office applications experience no authentication issues.
Ensure you have your Microsoft account credentials handy and verify your internet connection is stable before attempting to clear local authentication data.
Perform Standard Account and Credential Resets
Clear local caches and reset the OneDrive client to eliminate corrupted authentication tokens that cause sign-in failures.
In many cases, the desktop client fails to authenticate because outdated or conflicting security certificates and cached credentials remain on your system. Clearing these forces the app to request a fresh token.
Navigate to Windows Settings > Accounts > Access Work or School. Select the problematic account and click 'Disconnect'.
Open the Start menu, search for 'Credential Manager', and open it. Under 'Windows Credentials', locate any entries containing 'OneDrive' or 'MicrosoftOffice' and select 'Remove'.
Press Windows Key + R to open the Run dialog. Type '%localappdata%\Microsoft\OneDrive\onedrive.exe /reset' and press Enter. Once the icon reappears in the system tray, try signing in again.
Contact Microsoft Support for Advanced Backend Resolution
If standard credential resets and reinstallations do not work, escalate the issue to Microsoft Support to fix backend directory mismatches.
Switch to WPS Office for Seamless Document Management
If persistent Microsoft account synchronization or sign-in errors are disrupting your workflow, consider using WPS Office. It provides a lightweight, integrated cloud environment that bypasses complicated directory authentication issues while keeping your documents accessible.
- 1. Download the installer: Visit the official WPS website and download the free installer for Windows.
- 2. Install the software: Run the setup file and follow the on-screen prompts to complete the installation in minutes.
- 3. Open your files directly: Launch WPS Office, sign in with a free account, and instantly open your existing Microsoft Office files from your local drive.

Frequently Asked Questions
What exactly does OneDrive error AADSTS50020 mean?
This error code indicates an authentication failure with Azure Active Directory. It typically happens when a user account from an identity provider does not exist in the specific Microsoft directory or tenant they are trying to access through the desktop client.
Why can I access OneDrive on the web but not on the desktop app?
Web browsers use isolated session cookies for authentication, while the desktop application relies on the Windows Credential Manager and local application tokens. If the local tokens become corrupted or conflict with other logged-in Office apps, the desktop sign-in will fail even if the account itself is fine.
Will resetting or reinstalling OneDrive delete my locally saved files?
No. Resetting or reinstalling the OneDrive application only clears the sync settings and application cache. Your actual files will remain completely safe on your local hard drive and in the cloud storage.





