Fix file locked for editing and read-only mode in OneDrive when using File Explorer — Office 2021 to Microsoft 365 Apps

Fix File Locked for Editing and Read-Only Mode in OneDrive When Using File Explorer

📄 Article

Fix File Locked for Editing and Read-Only Mode in OneDrive When Using File Explorer

A user reported that Office files synced through OneDrive were opening in read-only mode from File Explorer and showing a file locked for editing message. However, the same files worked correctly in OneDrive Online, where co-authoring was functioning without issues.

After investigation, the issue was traced to the locally installed Office version. The device was using Microsoft Office 2021, which did not provide the required Microsoft 365 cloud-connected co-authoring experience in this scenario. Replacing it with the latest Microsoft 365 Apps resolved the issue.

🔍 The Symptoms

File locked for editing
This file is read-only
The document opens in read-only mode when accessed from File Explorer

💡 Key Observation

The issue was not reproducible in OneDrive Online. The user was able to open, edit, and co-author the same files successfully in the browser. The problem occurred only when opening files through File Explorer from the locally synced OneDrive folder.

🧠 Root Cause

The issue occurred because the files were opening with Microsoft Office 2021 installed on the device. While Office 2021 can open Office documents, it does not provide the same continuously updated Microsoft 365 cloud-connected feature set as Microsoft 365 Apps for enterprise or Microsoft 365 Apps for business.

For modern OneDrive and SharePoint co-authoring, the local Office client must support the required collaboration features, authentication experience, AutoSave behaviour, and cloud file locking mechanisms. In this case, Office 2021 was causing files to open in read-only mode or appear locked when accessed through File Explorer.

💡 Isolation Confirmation

Since OneDrive Online worked correctly, the issue was isolated to the local Office desktop application — not the file itself, OneDrive permissions, or SharePoint Online document library access.

🛠️ Step-by-Step Resolution

1

Verify the Behaviour in OneDrive Online

First, confirm whether the issue occurs only in the local Office desktop app or also in the browser. This isolates whether the problem is client-side or service-side.

  1. Open microsoft365.com
  2. Go to OneDrive
  3. Browse to the affected file
  4. Open the file in Word for the web, Excel for the web, or PowerPoint for the web
  5. Ask another user to open the same file and test co-authoring
  6. Confirm whether both users can edit the document at the same time

✅ Result in This Case

Co-authoring worked correctly in OneDrive Online. This confirmed that the cloud file, permissions, and OneDrive service were functioning as expected.

2

Test Local File Behaviour from File Explorer

Test whether the issue happens only when opening the file from the synced OneDrive folder.

  1. Open File Explorer
  2. Browse to the user’s synced OneDrive folder
  3. Open the affected Office file
  4. Check whether the file opens in read-only mode
  5. Check whether the user receives a file lock message
  6. Test another Office file from the same synced location

⚠️ Result in This Case

Files continued to open in read-only mode when launched from File Explorer, confirming the issue was not isolated to a single file.

3

Save a Local Copy and Retest

A local copy test helps confirm whether the issue is related to the synced file path or the Office desktop application itself.

  1. Copy the affected file to a local folder such as Documents or Desktop
  2. Open the copied file using the installed Office desktop application
  3. Edit and save the file
  4. Reopen the file and check whether the read-only behaviour persists

⚠️ Result in This Case

The issue persisted even after saving the file locally. This indicated that the problem was not limited to the OneDrive sync folder and pointed to the Office desktop application itself.

4

Check the Installed Office Version

Since the browser-based experience worked and the local Office experience failed, validate the installed Office version on the device.

GUI Method

  1. Open any Office application such as Word or Excel
  2. Go to File → Account
  3. Check the product name under Product Information
  4. Confirm whether the installed product is Microsoft Office 2021, Office LTSC 2021, Microsoft 365 Apps for enterprise, or Microsoft 365 Apps for business

⚠️ Result in This Case

The device was using Microsoft Office 2021 — a perpetual licence product without the continuous cloud-connected updates required for modern OneDrive co-authoring.

PowerShell Method

PowerShell — Check Click-to-Run Office Version

$OfficeConfigPath = "HKLM:\SOFTWARE\Microsoft\Office\ClickToRun\Configuration"

Get-ItemProperty -Path $OfficeConfigPath |
Select-Object `
    ProductReleaseIds,
    ClientVersionToReport,
    UpdateChannel,
    Platform,
    InstallationPath
PowerShell — Check Office Version from Uninstall Registry

$OfficeUninstallPaths = @(
    "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\*",
    "HKLM:\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\*"
)

Get-ItemProperty -Path $OfficeUninstallPaths -ErrorAction SilentlyContinue |
Where-Object {
    $_.DisplayName -like "*Office*" -or
    $_.DisplayName -like "*Microsoft 365 Apps*"
} |
Select-Object DisplayName, DisplayVersion, Publisher, InstallLocation
5

Confirm OneDrive Sync Client Status

Before changing Office versions, also confirm that the OneDrive sync client is running correctly and the correct account is connected.

GUI Method

  1. Select the OneDrive cloud icon in the Windows notification area
  2. Select Help & Settings
  3. Select Settings
  4. Confirm that the correct work account is connected
  5. Confirm that there are no sync errors
  6. Check whether the affected folder is syncing correctly

PowerShell Method

PowerShell — Check OneDrive Process

Get-Process OneDrive -ErrorAction SilentlyContinue |
Select-Object Name, Id, StartTime
PowerShell — Check OneDrive Client Version

$OneDrivePath = "$env:LOCALAPPDATA\Microsoft\OneDrive\OneDrive.exe"

if (Test-Path $OneDrivePath) {
    (Get-Item $OneDrivePath).VersionInfo |
    Select-Object ProductVersion, FileVersion
}
else {
    Write-Host "OneDrive.exe was not found in the expected user profile path."
}
6

Uninstall Office 2021

After confirming that Office 2021 was the local application opening the files, uninstall it from the device.

Option A — Settings App

  1. Open Settings
  2. Go to Apps → Installed apps
  3. Search for Microsoft Office 2021
  4. Select Uninstall
  5. Restart the device after the uninstall completes

Option B — Control Panel

  1. Open Control Panel
  2. Go to Programs → Programs and Features
  3. Select Microsoft Office 2021
  4. Select Uninstall
  5. Restart the device
7

Install Microsoft 365 Apps

Install the latest Microsoft 365 Apps version assigned to the user through the organisation’s Microsoft 365 subscription.

  1. Go to microsoft365.com
  2. Sign in with the user’s work or school account
  3. Select Install apps
  4. Download and install Microsoft 365 Apps
  5. Open Word or Excel after installation
  6. Sign in with the user’s Microsoft 365 work account
  7. Confirm activation under File → Account

💡 Admin Deployment Tip

For enterprise deployments, Microsoft 365 Apps can also be deployed through Intune, Microsoft Endpoint Configuration Manager, or the Office Deployment Tool (ODT) — ensuring the correct update channel and configuration are applied consistently across devices.

8

Validate Co-Authoring After Upgrade

After installing Microsoft 365 Apps, validate that co-authoring works from both OneDrive Online and File Explorer.

  1. Open the affected file from File Explorer
  2. Confirm that the file opens in edit mode
  3. Ask another user to open the same file from OneDrive or SharePoint
  4. Confirm that both users can edit the document at the same time
  5. Confirm that AutoSave is available and enabled
  6. Verify that the file no longer opens in read-only mode
  7. Confirm that the file lock error no longer appears

✅ Result in This Case

After upgrading to Microsoft 365 Apps, the issue was fully resolved. The user was able to edit and co-author files successfully without receiving the lock or read-only error.

✅ Validation Checklist

Check Expected Result
OneDrive Online editing ✅ Works successfully
Browser co-authoring ✅ Works successfully
Local File Explorer opening ✅ File opens in edit mode
Office version ✅ Microsoft 365 Apps installed
User sign-in ✅ User signed in with work account
AutoSave ✅ Available and enabled
OneDrive sync status ✅ No sync errors
File lock error ✅ No longer appears

💡 Best Practices & Recommendations

  • Use Microsoft 365 Apps for enterprise or Microsoft 365 Apps for business for the best OneDrive, SharePoint, and Teams file collaboration experience
  • Avoid mixing perpetual Office versions such as Office 2021 with Microsoft 365 cloud collaboration workflows where real-time co-authoring is required
  • Keep the OneDrive sync client and Microsoft 365 Apps updated to ensure compatibility with the latest collaboration and file locking features
  • Store shared business documents in SharePoint Online or Teams-connected document libraries instead of relying on local-only file copies
  • When troubleshooting file lock issues, always compare browser behaviour with local Office behaviour. If the file works online but fails locally, the issue is usually related to the Office client, sync client, authentication, or local cache

📝 Conclusion

💡 Summary

The issue was caused by the local Office desktop version. Files opened correctly in OneDrive Online, but when accessed through File Explorer, they opened using Microsoft Office 2021 and showed file lock or read-only behaviour.

After uninstalling Office 2021 and installing the latest Microsoft 365 Apps version, the user was able to open, edit, and co-author files normally. The file locked for editing error was resolved, and the files no longer opened in read-only mode.

📚 References & Further Reading

Explore More OneDrive for Business Resources

Continue learning with our complete OneDrive for Business administration guide and interview preparation resources.

Leave a Comment

Your email address will not be published. Required fields are marked *