Can't Rename Files or Folders in Windows 10? Fix It
In this article
Yes, you can fix the “Cannot rename folders or files in Windows 10” error yourself in a few minutes. The problem usually comes from a locked file, a background program, or a permissions setting. This guide walks you through the exact steps to regain control of your files.
in t | Finish time | min | 50 | 0 in d | Distance | km | 10 | 0 out pace | Average pace | min/km | t / d | 2 out speed | Average speed | km/h | d / (t / 60) | 2
Why Windows 10 Sometimes Blocks Renaming
Windows 10 prevents you from renaming a file or folder when it is open in another program. For example, a Word document that is still open in Microsoft Word, a photo being viewed in an image editor, or a PDF open in a browser will all lock the file. The same applies to folders: if any file inside a folder is in use, the folder itself may refuse to be renamed. Another common cause is a corrupted thumbnail cache, which can make Windows think a file is still being accessed. Antivirus software scanning a file at that exact moment can also trigger the error. Less often, your user account lacks the necessary permissions to modify the file, especially if it was created by another user or the system.
Quick Fixes to Try First
Before diving into advanced steps, try these simple solutions. They resolve a large percentage of cases.
- Close all programs: Save and close every open application, including background apps like OneDrive, Google Drive, or Dropbox. Right-click the app icon in the system tray (bottom-right corner) and choose “Exit” or “Quit”.
- Restart File Explorer: Press
Ctrl + Shift + Escto open Task Manager. Find “Windows Explorer” in the list, right-click it, and select “Restart.” This refreshes the shell and often releases temporary locks. - Reboot your PC: A full restart closes all background processes and clears the thumbnail cache. After restarting, try renaming again.
- Check if the file is read-only: Right-click the file, select “Properties,” and under the “General” tab, ensure the “Read-only” checkbox is unchecked. Apply the change to all subfolders if it’s a folder.
How to Unlock a File That Is Still in Use
If the simple steps didn’t work, a background process is likely holding the file. You can find out which process and close it safely.
- Press
Ctrl + Shift + Escto open Task Manager. - Click the “Details” tab to see all processes, including background ones.
- Look for the program that might be using the file (e.g., Microsoft Word, Adobe Reader, or your photo viewer). If you’re unsure, try ending processes one by one, but avoid closing system-critical processes like “System” or “Windows Explorer” (unless you plan to restart it).
- After closing the suspected program, try renaming again.
If you still can’t identify the culprit, you can use the built-in Resource Monitor: press Win + R, type resmon, and press Enter. Go to the “CPU” tab, expand “Associated Handles,” type the file name in the search box, and it will list which process has the file open. End that process from Task Manager.
Fix File Permissions to Allow Renaming
Sometimes the issue is that your account doesn’t have “Full Control” over the file or folder. This often happens with files from an old Windows installation or from another user profile. To fix it:
- Right-click the file or folder and select “Properties.”
- Go to the “Security” tab and click “Advanced.”
- Next to “Owner,” click “Change.”
- Type your Windows username and click “Check Names,” then “OK.”
- Check the box “Replace owner on subcontainers and objects” if it’s a folder.
- Click “OK” and then in the permissions list, select your user and ensure “Full control” is allowed.
Clear the Thumbnail Cache and Corrupted Data
A corrupted thumbnail cache can cause phantom locks. Clearing it is safe and will not delete your files. Open File Explorer, go to the “View” tab, and check “Hidden items” in the Show/hide section. Then navigate to %LocalAppData%\Microsoft\Windows\Explorer (paste this into the address bar). You’ll see files named thumbcache_*.db. Close all File Explorer windows, then delete all those files. They will be rebuilt automatically. If the problem persists, you can also run the System File Checker: open Command Prompt as administrator and type sfc /scannow. This repairs corrupted system files that might interfere with file operations.
When to Use Command Prompt or PowerShell
If the graphical interface still refuses, you can rename via command line. Open Command Prompt or PowerShell as administrator (right-click the Start button and choose “Windows PowerShell (Admin)”). Use the ren command: ren "C:\path\to\oldname.txt" "newname.txt". For folders: ren "C:\path\to\oldfolder" "newfolder". If the command works, the problem was with Explorer’s cache. If it fails, the file is truly locked by a process, and you’ll need to find and close that process as described above.
Frequently Asked Questions
Why can’t I rename a file that isn’t open?
Even if you don’t have the file open visibly, a background process might be using it. Common culprits are antivirus scans, cloud sync clients, or Windows Search indexing. Wait a few minutes and try again, or restart the computer to clear all locks.
What does “The action can’t be completed because the folder is open in another program” mean?
It means a program is currently accessing the folder or a file inside it. This could be a media player playing a song in that folder, a PDF viewer, or even a command prompt that has that folder as its current directory. Close all programs and try again.
Can I rename a file if I’m not the administrator?
You need at least “Modify” permission on the file. If you’re not the administrator, you may be able to rename if the administrator gave you permission. Otherwise, you’ll need to ask the administrator to grant you rights or perform the rename for you.
Why does renaming a folder sometimes fail because of a file inside it?
Windows treats a folder as a container. If any file within it is open or locked, the folder itself is considered “in use.” Close all files inside the folder, and also check if any program has a file in that folder as its current working directory (e.g., a command prompt or an editor’s recent files list).
Is it safe to use third-party unlocker tools?
Many are safe, but some bundle unwanted software or may force-close system processes. It’s better to use the built-in methods first. If you must use a third-party tool, download it from a reputable source and read reviews. Always create a restore point before using such tools.
What if I still can’t rename after all these steps?
If the problem persists, the file may be corrupted or the drive may have errors. Run chkdsk C: /f in Command Prompt (as admin) to check the disk. If the file is on an external drive, try connecting it to another computer. In rare cases, the file system itself is damaged, and you may need to back up your data and reformat the drive.