Excel shows a File in Use dialog saying your workbook “is locked for editing by another user”, sometimes even when that user is you. The cause is usually one of three things: your own session on another device or a crashed session, a real coworker who has the file open, or a co-authoring setup that has fallen back to one-editor-at-a-time locking.
Excel File Locked for Editing by Another User: Quick Reference
| Symptom | Likely cause | Go to |
|---|---|---|
| The lock names you, or you’re the only person who uses the file | The file is still open on another device, or an earlier session didn’t close cleanly | Fix #1, Fix #2 |
| Excel is frozen or won’t close | A hung Excel process is still holding the file | Fix #2 |
| A coworker really is in the file | Normal locking behavior | Fix #3 |
| A cloud file stays locked after everyone closes it | OneDrive sync is paused or out of date | Fix #4 |
| A file on a local or network folder stays locked after everyone closes it | A leftover ~$ temporary file | Fix #5 |
| You and a coworker both have the file open but can’t see each other’s edits | Unsupported Excel version, file format, or storage location | Fix #6 |
| Co-authoring fails even though versions and formats look right | Shared Workbook, a password, refresh-on-open, or an add-in | Fix #7 |
If the file opens but you can’t type in it, that’s a different problem. Protected View, read-only mode, and sheet protection are covered in our guide on why you can’t type in Excel.
Quick Diagnosis
Microsoft’s support article on this error starts by having you rule yourself out first (Microsoft Support, retrieved November 1, 2026). Use these checks:
- Read the name in the dialog. If it’s your name or your account, the lock is most likely yours, though a stale session can also show your name.
- Check where the file lives. Is it in OneDrive or SharePoint, or in a local or network folder? The fixes differ.
- Ask anyone who shares the file whether they have it open right now.
Fixes for a Locked Excel File
Fix #1: Close the File Everywhere and Wait
Symptoms: The lock shows your own name, or no one else uses the file.
Why it happens: The workbook is still open on your laptop, tablet, phone, or in a browser tab. Or a previous session ended badly through a crash, forced shutdown, or dropped network connection, and never released its claim on the file.
- Close the workbook in Excel on every computer you use.
- Close it in the Excel app on your phone or tablet.
- Close any browser tabs where the file is open in Excel for the web.
- Wait a few minutes. Microsoft notes that the server can take some time to recognize that the file is no longer open.
- Reopen the workbook.
Verify: The file opens without the File in Use dialog, and the title bar doesn’t say Read-Only.
Fix #2: End Excel in Task Manager
Symptoms: Excel is frozen, won’t close, or you closed it but the lock remains.
Why it happens: A hung Excel process keeps running in the background and still holds the file.
- Save any other open workbooks if Excel responds at all.
- Press
Ctrl + Shift + Escto open Task Manager. - On the Processes tab, select Microsoft Excel. You can also go to the Details tab and select
EXCEL.EXE. - Click End task.
- Wait a minute or two, then reopen the workbook.
Verify: The workbook opens for editing. If a recovery pane appears, review the recovered versions before you discard them.
Fix #3: Request More Access or Save a Copy
Symptoms: A real coworker has the file open, and you need to get in now.
Why it happens: This isn’t a bug. Locking stops two people from overwriting each other’s work.
The simplest option is to open the file as Read Only and ask your coworker to close it. For files in OneDrive or SharePoint where you only have view access, you can use Request more access. The exact label and menu wording can vary by Excel version and Microsoft 365 plan.
- Select Viewing (or similar wording) in the upper-right corner of Excel.
- Choose Request more access.
- Pick Ask to edit or Ask to review.
- Add an optional note, then send the request. The file’s owner gets an email.
If you have to make changes right away, work on your own copy:
- Open the file as Read Only.
- Go to File > Save As > Browse.
- Give the copy a new name, then click Save.
- Merge your changes into the original once it’s free.
Verify: You either get an access email reply or have an editable copy with your name on it.
Fix #4: Check and Resume OneDrive Sync
Symptoms: A cloud file stays locked after everyone has closed it, or recent changes aren’t showing up.
Why it happens: Microsoft’s locked-file guidance says to make sure OneDrive syncing isn’t paused and that you’re on the latest sync app. A paused or outdated sync client is one common reason a cloud file’s lock can look stuck, though it isn’t the only one.
- Click the OneDrive cloud icon in the Windows 11 system tray.
- Check the sync status message.
- If syncing is paused, open the settings menu and choose the resume option. The exact wording can vary between OneDrive versions.
- Install any OneDrive update the flyout offers.
- Let syncing finish, then reopen the workbook.
Verify: The flyout reports that your files are up to date, and the workbook opens normally.
Fix #5: Delete the Leftover ~$ Temporary File
Symptoms: A workbook in a local or network folder still shows as locked after everyone has closed it.
Why it happens: While a workbook is open, Excel typically creates a temporary hidden file whose name starts with ~$, followed by the workbook’s name (for example, ~$Budget.xlsx). This is long-standing, widely observed Excel behavior, though it isn’t spelled out in Microsoft’s official locked-file support article.
Excel normally removes this file when you close the workbook. After a crash or forced shutdown, the temporary file can be left behind and make the next person think the file is still in use.
Important: Only do this after you’ve confirmed that no one has the file open. Deleting this temporary file is a widely used troubleshooting step, though it’s not documented as an official fix in Microsoft’s locked-file support article, and it only applies to files stored in local or network folders. For cloud files stored in OneDrive or SharePoint, use Fix #1 and Fix #4 instead.
- Open File Explorer and go to the folder that contains the workbook.
- Select View > Show > Hidden items.
- Find the file that starts with
~$and matches your workbook’s name. - Right-click it and choose Delete.
- Reopen the workbook.
Verify: The ~$ file is gone, and the workbook opens without the lock message. When you open the workbook, Excel creates a fresh temporary file. That’s expected.
Fix #6: Check Co-authoring Requirements
Symptoms: You and a coworker can’t edit the same file together. One of you always gets locked out.
Why it happens: Co-authoring only works under certain conditions. When any condition isn’t met, Excel falls back to letting one editor in at a time. Everyone else sees the file as locked.
Microsoft lists co-authoring support for these apps:
- Excel versions: Excel for Microsoft 365 on Windows and Mac, and Excel for the web.
- File formats:
.xlsx,.xlsm, or.xlsb. - Storage location: OneDrive or SharePoint.
Older one-time-purchase versions such as Excel 2016, 2019, and 2021 LTSC don’t co-author the way Microsoft 365 does. Check current Microsoft documentation for your exact version.
Files kept on a network share or in a third-party sync folder, such as Dropbox, Box, or Google Drive, generally don’t support Microsoft’s co-authoring and may fall back to single-editor locking instead. Move shared workbooks to OneDrive or SharePoint if you need real-time co-authoring with Microsoft 365.
To fix the version:
- Have everyone open File > Account to see which version of Excel they have.
- Click Update Options > Update Now to install the latest build.
People on a one-time-purchase version need a Microsoft 365 subscription to co-author. Microsoft 365 Personal, Microsoft 365 Family, and Microsoft 365 Business Basic all include it. Business Basic gives you web and mobile Excel only. Compare plans on Microsoft’s plans page.
To fix the file format:
- Open the workbook and go to File > Save As > Browse.
- Open the Save as type dropdown.
- Choose *Excel Workbook (.xlsx)**. Choose
.xlsmif the file contains macros.
- Save the file to OneDrive or SharePoint, then share that copy.
Verify: Both people open the file, and each sees the other’s presence and edits.
Fix #7: Remove In-Workbook Co-authoring Blockers
Symptoms: Everyone has Microsoft 365 and the right format, but co-authoring still fails.
Why it happens: Some workbook features block co-authoring. They include the legacy Shared Workbook feature, password encryption, data set to refresh on open, and some add-ins.
Turn off the legacy Shared Workbook feature. If the title bar shows [Shared], turn it off with the Share Workbook (Legacy) command. You may need to add this command to the ribbon or the Quick Access Toolbar first. Then clear the option to allow changes by more than one user.
Remove password encryption:
- Go to File > Info > Protect Workbook.
- Choose Encrypt with Password.
- Delete the password, then click OK.
- Save the workbook.
Turn off refresh-on-open:
- Select a table or PivotTable that’s connected to external data.
- Open its connection properties. In current Microsoft 365 builds, you’ll typically find them under Data > Queries & Connections: right-click the connection and choose Properties. Depending on whether you selected a table or a PivotTable, and on your Excel version, you may instead need Table Design > Refresh > Connection Properties or PivotTable Analyze > Refresh > Connection Properties.
- On the Usage tab, clear Refresh data when opening the file.
- Click OK, then repeat for each connection in the workbook.
Disable suspect add-ins:
- Go to File > Options > Add-ins.
- Set Manage to Excel Add-ins and click Go.
- Uncheck an add-in, then click OK.
- Test co-authoring. Re-enable add-ins one at a time to find the one causing trouble.
Verify: Two Microsoft 365 users can edit the file at the same time without anyone getting the lock dialog.
Error Messages Explained
| Message or state | What it means | Fix |
|---|---|---|
| “is locked for editing by another user” | Excel thinks someone else has the file open. It may be a real person or a stale lock | Fix #1, #3, #5 |
| “is locked for editing by” followed by your own name | Your other device or a crashed session holds the lock | Fix #1, #2 |
| File in Use dialog with Read Only / Notify / Cancel | Read Only typically opens a view-only copy, and Notify is generally understood to alert you once the file is free, though exact behavior can vary by Excel version | Fix #3 |
| Viewing label (or similar wording) in the upper right | Usually indicates you have view-only access to a file stored in OneDrive or SharePoint | Fix #3 (Request more access) |
| Coworker’s edits never appear | Co-authoring isn’t active, so Excel is using exclusive locking | Fix #6, #7 |
Platform-Specific Notes
On Windows
All of the steps above use Windows 11 with Microsoft 365. On Windows 10, File Explorer’s hidden-items toggle is under the View tab as a Hidden items checkbox.
On macOS
- Press
Option + Command + Esc, select Microsoft Excel, and click Force Quit if Excel is frozen.
- Update Excel with Help > Check for Updates, which runs Microsoft AutoUpdate.
- Check sync status from the OneDrive icon in the menu bar.
- To show hidden files in Finder, press
Command + Shift + .(period). Apply the same rule as on Windows: only delete a~$file in a local or network folder after you’ve confirmed no one has the file open.
On Excel for the Web
Excel for the web supports co-authoring. Close any leftover browser tabs that have the workbook open, because they count as open sessions.
Excel for the web generally offers similar view-only indicators and an option to request edit access, though the exact wording and placement can differ from the desktop app and change between updates.
Settings to Check
- OneDrive sync: Open the system tray flyout. It shouldn’t be paused.
- Workbook encryption: Under File > Info > Protect Workbook, there should be no password.
- Refresh on open: In Connection Properties > Usage, the checkbox should be cleared.
- Add-ins: Under File > Options > Add-ins, disable any you don’t need.
- Excel version: Under File > Account, you should have a current Microsoft 365 build.
Getting Help
Start with Microsoft’s Excel file is locked for editing page. If Excel crashes or hangs when you close it, check the Current Channel release notes. Microsoft periodically lists fixes there for Excel crashes and hangs, so updating to the latest build is worth trying.
Updates can help with related crash problems but aren’t guaranteed to cure a lock. If your organization uses SharePoint check-in/check-out policies, ask your admin. That’s an admin setting, not something you can change in Excel. When you contact support, have your Excel version, the file’s location, and the exact dialog text ready.
Prevention Tips
- Close files before switching devices: Close the workbook on one device before you open it on another.
- Leave OneDrive running: Pause syncing only briefly, and resume it before you open shared files.
- Use modern formats: Store shared workbooks as
.xlsxin OneDrive or SharePoint. - Avoid forced shutdowns: A UPS on your desktop PC prevents power-loss crashes that leave
~$files behind.
Frequently Asked Questions
Why does Excel think I have the file open when I don’t?
The file is still open on another device or browser tab, or a crashed session never released the lock. Close it everywhere and wait a few minutes.
Is it safe to delete a ~$ file?
This is a commonly used troubleshooting step, though not an officially documented Microsoft fix. Only try it if no one has the workbook open and the file lives in a local or network folder, and don’t use it to try to fix an OneDrive or SharePoint cloud lock — use the OneDrive sync fix instead.
Does pausing OneDrive cause file lock problems?
It can. While syncing is paused, lock changes aren’t communicated, so a file can look stuck as locked.
Wrapping Up
Most of the time, the “other user” is you. Closing the file everywhere and waiting a few minutes (Fix #1), or ending a frozen Excel process (Fix #2), clears it up.
If the lock keeps coming back between two Microsoft 365 users, look at co-authoring blockers like refresh-on-open or an old .xls format before you blame your coworker. If Excel crashes often enough to keep leaving ~$ files behind, look at add-ins, your Excel build, and the PC’s overall stability.
| Step | Action | Applies to |
|---|---|---|
| 1 | Close the file everywhere and wait | All |
| 2 | End Excel in Task Manager or Force Quit | Windows, Mac |
| 3 | Request more access or save a copy | OneDrive and SharePoint files |
| 4 | Resume or update OneDrive | Cloud files |
| 5 | Delete the leftover ~$ temporary file | Local and network files only |
| 6–7 | Fix version, format, and workbook blockers | Co-authoring |
Last updated: November 1, 2026 | Applies to Excel for Microsoft 365 on Windows and Mac, and Excel for the web