How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (2024)

Quick Links

  • What is Windows File Recovery?
  • How to Install Windows File Recovery
  • How to Recover Deleted Files on Windows 10 and Windows 11
  • Which Recovery Mode Should You Use?
  • How to Recover a File in Default Mode
  • How to Recover a File in Segment Mode
  • How to Recover a File in Signature Mode
  • More Help With winfr

Ever accidentally deleted a file and then realized you needed it? Or had a drive experience some kind of corruption? Microsoft's Windows File Recovery tool may be able to bring back your lost files — here's how to use it.

What is Windows File Recovery?

Windows File Recovery is a program created by Microsoft designed to recover files that have been deleted. Windows File Recovery tool doesn't have a graphical interface — it's only a command-line utility. We'll show you how to use it, but it's a more hands-on process than you might expect from an official Microsoft utility available in the Microsoft Store.

This tool requires you've installed Windows 10's May 2020 Update or newer, or any version of Windows 11. It doesn't run on older versions of Windows.

Whether Microsoft's tool can actually find and recover a file you've deleted depends on the drive. Deleted files aren't removed from hard drives immediately, but they often are removed from solid-state drives immediately. If you've written a lot of data to a device like an SD card since you've deleted the file, it's likely that the file's data may have been overwritten.

Even if you manage to recover a file, you may only get some of the file's data — the file may be corrupted. You can only get whatever data is still on the drive. There are no guarantees here, and that's why backups are so important.

The utility also has multiple modes intended for different situations and file systems. We'll explain which you should use and how to use them.

How to Install Windows File Recovery

To get started, install the Windows File Recovery tool from the Microsoft Store to get started. You can open the Store and search for "Windows File Recovery" or just click that link to open the Store.

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (1)

Once it's installed, open your Start menu and search for "File Recovery." Launch the "Windows File Recovery" shortcut once and click "Yes" to the UAC prompt.

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (2)

You'll see a Command Prompt window with Administrator access. This is where you'll run the File Recovery commands.

You can use other command-line environments like the Windows Terminal and PowerShell, but be sure to launch them with Administrator access. (In the Start menu, right-click the one you want to use and select "Run as Administrator.")

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (3)

How to Recover Deleted Files on Windows 10 and Windows 11

To use Windows File Recovery, you will run the winfr command, specifying the drive you want to search for the deleted file, the destination you want to save it to, and the various switches that control what the tool searches for and how it searches. You must save the deleted file to a different drive.

Here's the basic format:

winfr source-drive: destination-drive: /switches

After running the command, the tool will automatically create a directory named "Recovery_[date and time]" on the destination drive you specify.

Which Recovery Mode Should You Use?

Before you continue, you should determine the "mode" you want to scan for the deleted file. There are three modes: Default, Segment, and Signature. Default is the fastest mode, while Segment is similar but slower and more thorough. Signature mode can search for files by type — it supports ASF, JPEG, MP3, MPEG, PDF, PNG, and ZIP files. (Searching for "ZIP" files will also find Office documents stored in formats like DOCX, XLSX, and PPTX.)

You'll need to know what file system the drive you'll be scanning is formatted with. To find this, open File Explorer, right-click the drive under This PC, and select "Properties." You'll see the file system displayed on the "General" tab.

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (4)

Here's when you should use the different modes:

  • Are you trying to find a file you recently deleted on a drive formatted with NTFS, which is the default Windows 10 and 11 file system? Use Default mode.
  • If you're scanning an NTFS drive in another situation — for example, if you deleted the file a while ago, you formatted the drive, or you're dealing with a corrupt drive — try Segment mode first and then try Signature mode afterward.
  • Are you trying to find a file stored on a FAT, exFAT, or ReFS drive? Use Signature mode. The Default and Segment modes only work on NTFS file systems.

If you're in doubt, just start with Default mode. You can then try Segment and then Signature if Default mode doesn't work.

How to Recover a File in Default Mode

To use the default mode, you use /n followed by a search path:

  • To search for a file named document.docx, you'd use /n document.docx . You can also specify a full path to the file, such as /n UsersBobDocumentsdocument.docx
  • To search for all files that were in the Documents folder if your username is Bob, you'd use /n UsersBobDocuments .
  • To search with a wildcard, use a *. For example /n UsersBobDocuments*.docx will find all DOCX files there were in the Documents folder.

Let's put that all together now. To search for all DOCX files on drive C: and copy them to drive D:, you'd run the following command:

winfr C: D: /n *.docx

You will have to type "y" to continue.

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (5)

As we mentioned above, you'll find the recovered files in a directory named "Recovery_[date and time]" on the destination drive you specified in the command line.

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (6)

To find all files with a word in their name, use wildcards. So, to find all documents with "project" anywhere in their name, you'd run:

winfr C: D: /n *project*

You can specify multiple searches with multiple /n switches. So, to find all Word, Excel, and PowerPoint files, you'd run the following:

winfr C: D: /n *.docx /n *.xlsx /n *.pptx

To search for a specific file named important_document.pdf that was in the Users/Bob/Documents folder on drive C: — and then save it to drive D: —you'd use:

winfr C: D: /n Users/Bob/Documents/important_document.pdf

How to Recover a File in Segment Mode

Segment mode works almost exactly like Default mode. To use segment mode, which examines file record segments, you use /r in addition to /n .

In other words, you can construct Segment mode recovery commands in the same way you construct Default mode commands---just add the /r .

For example, to recover all deleted MP3 files from your C: drive and save them to your D: drive, you'd run:

winfr C: D: /r /n *.mp3

So, if a Default mode search doesn't find what you're looking for, add the /r and try again.

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (7)

How to Recover a File in Signature Mode

Signature mode works a bit differently. It examines file types, so it can only find deleted files of certain file types. To use Signature mode, you use /x to specify Signature mode and /y: to list the file type groups you'd like to search for.

Here's a list of supported file types and the groups they're sorted into, taken from Microsoft's documentation:

  • ASF: wma, wmv, asf
  • JPEG: jpg, jpeg, jpe, jif, jfif, jfi
  • MP3: mp3
  • MPEG: mpeg, mp4, mpg, m4a, m4v, m4b, m4r, mov, 3gp, qt
  • PDF: pdf
  • PNG: png
  • ZIP: zip, docx, xlsx, pptx, odt, ods, odp, odg, odi, odf, odc, odm, ott, otg, otp, ots, otc, oti, otf, oth

Note that the "ZIP" group includes ZIP files in addition to Microsoft Office and OpenDocument documents.

You can pull up this list at any time by running the following command:

winfr /#
How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (8)

Let's say you want to search drive E: for images in JPEG format and save them to drive D:. You'd run the following command:

winfr E: D: /x /y:JPEG

You can specify multiple file groups by separating them with a space. So, if you want to find JPEG files, PDFs, and Word documents, you'd run:

winfr E: D: /x /y:JPEG,PDF,ZIP
How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (9)

More Help With winfr

More information is available on Microsoft's official winfr documentation page. You'll find a detailed list of all winfr 's command-line options on that page, too.

For a refresher on the basics, just run winfr or winfr /? .

There are also additional advanced options you can see by running winfr /! .

How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (10)
How to Use Microsoft's "Windows File Recovery" on Windows 10 and Windows 11 (2024)

References

Top Articles
Latest Posts
Article information

Author: Nathanael Baumbach

Last Updated:

Views: 6168

Rating: 4.4 / 5 (55 voted)

Reviews: 94% of readers found this page helpful

Author information

Name: Nathanael Baumbach

Birthday: 1998-12-02

Address: Apt. 829 751 Glover View, West Orlando, IN 22436

Phone: +901025288581

Job: Internal IT Coordinator

Hobby: Gunsmithing, Motor sports, Flying, Skiing, Hooping, Lego building, Ice skating

Introduction: My name is Nathanael Baumbach, I am a fantastic, nice, victorious, brave, healthy, cute, glorious person who loves writing and wants to share my knowledge and understanding with you.