Folders Turned into Shortcuts in Windows: What It Usually Means
If every folder on a drive suddenly appears as a small shortcut with an arrow icon, the most common cause is shortcut malware. This type of infection usually hides your real folders, creates fake .lnk shortcut files with the same names, and runs a malicious script when you open one of those shortcuts.
Stop clicking shortcuts
Close File Explorer windows that point to the infected drive and avoid double-clicking .lnk files.
Reveal hidden folders
Use File Explorer settings or the attrib command to check whether your real data is hidden.
Scan and clean
Run Microsoft Defender or another trusted scanner against both Windows and the affected drive.
Back up safely
Copy only recovered documents, photos, and other real files — not suspicious scripts or shortcuts.
How to Recognize a Shortcut Virus on a USB Drive or Disk
The problem often appears after using a USB drive on another computer, copying files from an unknown source, or connecting a memory card to an infected PC. The drive may look almost normal, but the visible folders are actually shortcut files.
Folder icons show the small shortcut overlay, and their properties identify them as Shortcut files instead of real folders.
The fake shortcuts may be only a few kilobytes, while the drive still shows used space in File Explorer.
You may see files such as autorun.inf, desktop.ini, .vbs, .cmd, or .js in the drive root.
If the same drive becomes infected again after cleanup, the Windows computer itself may still contain an active startup entry.
| What you see | Likely meaning | What to do |
|---|---|---|
| Folders changed to shortcuts | Real folders are probably hidden and fake .lnk files were created. |
Do not open the shortcuts; reveal hidden folders first. |
| Drive space is still used | Your files may still be present, but marked as hidden or system. | Use the attrib recovery command. |
| Suspicious script files | The shortcut may launch a script before opening the real folder. | Scan the drive and delete only clearly malicious leftovers after scanning. |
| New USB drives also get infected | Windows may still have malware in startup, scheduled tasks, or user profile folders. | Scan the whole PC and check startup locations. |
First Actions Before Fixing Shortcut Folders in Windows
Treat the affected drive as potentially infected until you finish scanning. The goal is to avoid launching the malware again while still preserving the original files.
- Do not double-click any shortcut that appeared unexpectedly on the drive.
- Disconnect other USB drives, external disks, cameras, and memory cards from the computer.
- Do not copy the fake shortcut files to another computer.
- Open File Explorer using Win + E, but avoid running unknown files from the affected drive.
- If the drive contains critical business or legal files, make a read-only image or ask a professional recovery service before deleting anything.
E: or F:. You will need the correct letter for the recovery command.
Recover Hidden Folders with the Attrib Command
If the drive still shows used space but your folders are hidden, use Command Prompt to remove the hidden, system, and read-only attributes from files and folders on the affected drive.
E: with the real drive letter of your affected drive. You can check it in This PC. Do not run the command against the wrong drive by mistake.
- Connect the affected drive to a computer that has antivirus protection enabled.
- Open Start, type cmd, right-click Command Prompt, and choose Run as administrator.
- Run the command below, changing the drive letter first.
Command Prompt — replace E: with your drive letterattrib -h -r -s /s /d E:\*.*
After the command finishes, open the drive again. The original folders should become visible. If you see both real folders and fake shortcuts, open only the real folders. Do not open the shortcut copies.
Scan the Infected Drive and Remove Shortcut Malware
Recovering hidden folders is not the same as removing the infection. You still need to scan the computer and the affected drive. Otherwise, the shortcuts may return after the next reboot or when you connect another USB drive.
Microsoft Defender Full Scan
Use Windows Security to scan the entire PC and the connected drive. This is the safest first pass for most users.
Recommended firstMicrosoft Defender Offline Scan
Run an offline scan if the malware keeps returning, closes security tools, or hides itself while Windows is running.
For persistent malwareSecond-opinion scanner
Use another trusted scanner if Defender removes something but the drive still creates shortcuts again.
Optional checkRun a Full Scan in Windows Security
- Open Start and search for Windows Security.
- Open Virus & threat protection.
- Click Scan options.
- Select Full scan and start the scan.
- After that, scan the removable drive directly from File Explorer if the option is available in the context menu.
When to use Microsoft Defender Offline
Use Microsoft Defender Offline scan if suspicious scripts return after deletion, new drives become infected automatically, or security tools close unexpectedly. Save your work first because Windows will restart.
Delete Malicious Shortcuts, Autorun Files, and Script Leftovers
After scanning, you can remove obvious remnants from the affected drive. Be careful: delete fake shortcuts and suspicious scripts, not your recovered folders.
Items that are often safe to remove after recovery
- Shortcut copies of your folders with the
.lnkextension. - Unknown
.vbs,.js,.cmd,.bat, or.scrfiles in the drive root. - Suspicious
autorun.inffiles on removable media. - Duplicate folders with strange names, random characters, or executable extensions.
You can also use Command Prompt to list shortcut and script files on the affected drive before deleting anything:
List suspicious file types — replace E: firstdir E:\*.lnk /a
dir E:\*.vbs /a
dir E:\*.js /a
dir E:\*.cmd /a
dir E:\autorun.inf /a
Check Windows Startup if Shortcut Folders Keep Coming Back
If the same drive gets infected again immediately, the malware may still be launching from the Windows user profile, Startup folder, Registry, or Task Scheduler. Check these areas only after running antivirus scans.
| Area to check | What to look for | How to open it |
|---|---|---|
| Task Manager startup list | Unknown entries with blank publishers or random names. | Press Ctrl + Shift + Esc, then open Startup apps. |
| Startup folder | Unexpected shortcuts, scripts, or executable files. | Press Win + R and run shell:startup. |
| Task Scheduler | Tasks that run scripts from temporary folders, user profile folders, or removable drives. | Search for Task Scheduler in Start. |
| Temporary folders | Suspicious scripts or executables with recent modification dates. | Press Win + R and run %temp%. |
When You Should Back Up Files and Format the Drive
If the affected drive is removable, formatting it after recovery is often the cleanest final step. Format only after you have copied the real files to a safe location and scanned that backup location.
Format the drive if
- The shortcut files return after manual deletion.
- The drive root contains many unknown scripts.
- The drive was used on several infected or unknown computers.
- You already recovered and backed up the important files.
Do not format yet if
- The only copy of important files is still on the affected drive.
- The drive shows used space but folders are still not visible.
- The drive has file system errors or asks to be formatted before opening.
- You need professional data recovery from the device.
How to format after recovery
- Copy recovered files to a clean folder on another drive.
- Scan the copied files with antivirus software.
- Open This PC.
- Right-click the affected removable drive and choose Format.
- Use exFAT for broad compatibility or
NTFSfor Windows-only storage with permissions and large files. - After formatting, copy back only clean, recovered files.
How to Prevent Folders from Turning into Shortcuts Again
Shortcut malware spreads mostly through removable drives and careless execution of scripts. Prevention is mainly about keeping automatic execution disabled, scanning unknown drives, and avoiding suspicious shortcuts.
- Keep Windows Security and security intelligence updates enabled.
- Scan USB drives before opening files from them.
- Do not open unexpected
.lnk,.vbs,.js,.cmd, or.scrfiles. - Keep file extensions visible in File Explorer so fake files are easier to notice.
- Avoid using personal USB drives on untrusted public computers.
- Back up important files to at least one location that is not always connected to the PC.
Show file extensions in Windows
- Open File Explorer.
- In Windows 11, choose View → Show → File name extensions.
- In Windows 10, open the View tab and enable File name extensions.
FAQ: Folders Became Shortcuts in Windows
Q Are my files deleted if folders turned into shortcuts? ⌄
attrib command before formatting.
Q Can I just delete all shortcut files? ⌄
.lnk files after you recover the original folders and scan the drive. Do not delete unfamiliar items blindly if you are not sure whether they are part of your data.
Q Why does the shortcut virus come back after I clean the USB drive? ⌄
Q Should I format the USB drive immediately? ⌄
Q Does this problem affect Windows 10 and Windows 11 the same way? ⌄
Final Recommendation
When folders turn into shortcuts, do not assume the files are gone. First stop opening shortcuts, reveal hidden folders, run the attrib command with the correct drive letter, scan both the drive and Windows, then delete fake shortcuts and suspicious scripts. If the drive is removable, back up clean recovered files and format the drive as the final safety step.