Remote workers who reset their Microsoft 365 password often see the 0x8004de40 sign-in error when opening OneDrive for Business. The error message typically reads “Sign in required” or “Something went wrong” with the code 0x8004de40. This happens because OneDrive caches your old credentials and cannot refresh them automatically after a password change. This article explains why the error occurs and provides a complete fix that restores OneDrive sync without reinstalling the app.
Key Takeaways: Fixing 0x8004de40 After Password Reset
- Windows Credential Manager > Windows Credentials > MicrosoftOffice16_Data:ADAL: Remove stale ADAL tokens that prevent fresh authentication after a password reset.
- OneDrive Settings > Account > Unlink this PC: Forces OneDrive to discard cached credentials and re-authenticate from scratch.
- OneDrive Process Restart via Task Manager: Ends hung OneDrive.exe processes so the sign-in flow starts cleanly.
Why the 0x8004de40 Error Appears After a Password Reset for Remote Workers
The 0x8004de40 error is a credential cache mismatch. When a remote worker changes their Microsoft 365 password, the local OneDrive client still holds the previous authentication token. OneDrive cannot use the old token to verify identity, but it also does not automatically prompt for new credentials. Instead, it returns error code 0x8004de40 and stops syncing.
The error is more common in remote work scenarios for two reasons. First, remote machines often connect through VPNs or conditional access policies that delay the password change propagation. Second, Windows Credential Manager stores ADAL tokens that are not cleared when the user changes their password through a web portal. These tokens remain valid for hours or days, causing OneDrive to attempt authentication with revoked credentials.
The fix requires removing the stale ADAL token from Credential Manager and unlinking OneDrive. This forces the client to request a fresh token using the new password. No registry edits or Group Policy changes are needed for this specific error.
Complete Steps to Fix OneDrive Error 0x8004de40 After Password Reset
Perform these steps in the exact order shown. Skipping the Credential Manager step will cause the error to return immediately after you sign in again.
Step 1: Remove Stale ADAL Tokens from Windows Credential Manager
- Open Credential Manager
Press the Windows key, type Credential Manager, and select the app from the search results. - Switch to Windows Credentials
Click Windows Credentials at the top of the window. Do not select Web Credentials or Certificate-Based Credentials. - Locate OneDrive and Office ADAL entries
Scroll down to the Generic Credentials section. Look for entries that contain:
– MicrosoftOffice16_Data:ADAL: followed by a GUID
– MicrosoftOffice16_Data:ADAL:WAM: followed by a GUID - Remove each ADAL entry
Click the arrow to expand the entry, then click Remove. Confirm the deletion. Remove all entries that start with MicrosoftOffice16_Data:ADAL. - Close Credential Manager
After removing all ADAL entries, close the Credential Manager window.
Step 2: Unlink OneDrive from This PC
- Open OneDrive Settings
Right-click the OneDrive cloud icon in the system tray near the clock. Select Settings. - Go to the Account tab
In the OneDrive settings window, click the Account tab at the top. - Click Unlink this PC
Under the account section, click Unlink this PC. Read the warning and click Unlink account to confirm. - Wait for the OneDrive setup window
After unlinking, the OneDrive setup window appears automatically. Do not sign in yet. Close the setup window for now.
Step 3: Restart the OneDrive Process
- Open Task Manager
Press Ctrl + Shift + Esc to open Task Manager. - End all OneDrive processes
In the Processes tab, look for Microsoft OneDrive. Select it and click End task. If you see multiple OneDrive entries, end each one. - Start OneDrive fresh
Press the Windows key, type OneDrive, and select the app. The OneDrive setup window opens.
Step 4: Sign In with Your New Password
- Enter your work or school email
In the OneDrive setup window, type your full Microsoft 365 email address and click Sign in. - Enter your new password
Type your updated password. If your organization uses multi-factor authentication, complete the MFA prompt. - Choose your sync folders
After authentication, OneDrive asks which folders to sync. Select your preferred folders and click Next. - Complete the setup
Click Open my OneDrive folder or Get started. OneDrive begins syncing with the new credentials.
If OneDrive Still Shows 0x8004de40 After the Main Fix
OneDrive shows the error again after signing in with the new password
This usually means a stale ADAL token was missed. Open Credential Manager again and look for any remaining entries that start with MicrosoftOffice16_Data:ADAL. Remove them and restart OneDrive again. Also check for entries under Web Credentials that reference Microsoft or Office. Remove those as well.
The error appears only on VPN-connected remote machines
Some VPN configurations delay DNS resolution for Microsoft 365 endpoints. Disconnect from the VPN, complete the sign-in steps, and then reconnect the VPN. If the error returns, check your VPN split-tunneling settings. Ensure login.microsoftonline.com and graph.microsoft.com are routed outside the VPN tunnel.
OneDrive prompts for credentials repeatedly even after the fix
This indicates a cached token in the Windows Web Account Manager. Open Settings > Accounts > Access work or school. Select your work or school account and click Disconnect. Then re-add the account from the same page. After disconnecting, restart OneDrive and sign in again.
Files On-Demand vs Always Keep on This Device: Key Differences
| Item | Files On-Demand | Always Keep on This Device |
|---|---|---|
| Description | Placeholder files that download only when opened | Full file content stored permanently on the local drive |
| Disk space usage | Minimal — only file metadata stored locally | Full file size consumed on the hard drive |
| Offline access | Requires explicit pinning of each file or folder | All designated files available offline by default |
| Sync behavior after password reset | Placeholder files may show error 0x8004de40 until re-authentication | Already synced files remain accessible offline; new sync requires fresh token |
| Best for | Remote workers with limited disk space or high file turnover | Users who need guaranteed offline access to specific project files |
After fixing the 0x8004de40 error, you can now sign in to OneDrive with your new password and resume syncing. To prevent this error from recurring, make it a habit to unlink OneDrive and remove ADAL tokens immediately after changing your Microsoft 365 password. For remote workers, consider enabling OneDrive Files On-Demand so that placeholder files do not consume bandwidth during re-authentication.