How to Find Duplicate Files on Windows 11 (Hashes, Not Filenames)
Published 2026-09-09 · Star Cleaner
Why are matching names and sizes not proof?
Two unrelated files can share a name, especially when they live in different folders. Copies can also be renamed. File size narrows the search, but different content can have the same length. An exact duplicate is defined by identical bytes, which a full-content cryptographic hash can verify.
How do you find exact duplicates with PowerShell?
- 1.Open PowerShell. Choose a user folder such as Pictures or Documents; do not begin with the whole system drive.
- 2.Run: Get-ChildItem -LiteralPath "$HOME\Pictures" -File -Recurse | Get-FileHash -Algorithm SHA256 | Group-Object Hash | Where-Object Count -GT 1 | ForEach-Object { $_.Group | Select-Object Path, Hash }
- 3.Review the printed path groups. Files in one group have the same SHA-256 content hash. The command only reports matches and does not delete anything.
What are the limits of the built-in method?
- PowerShell must read every file to calculate its hash, so a large media library can take a long time.
- It finds only byte-identical files. An edited, resized, or re-encoded copy receives a different hash.
- It cannot tell that two different photos show the same moment, such as a burst or retake.
What does perceptual hashing solve?
Perceptual hashing compares visual structure rather than exact bytes. It can place retakes, resized exports, and lightly edited copies into similar-photo groups while keeping exact duplicates separate. Windows 11 has no built-in tool for this second problem, and similarity still requires a human keep-choice.
How do you delete duplicate files safely?
- Open and review every match, then keep one copy in the location that belongs in your filing system.
- Never bulk-delete inside Windows, Program Files, Program Files (x86), or application folders. Repeated support files may be required in separate locations.
- Check OneDrive status before acting. A file that looks local may be an online-only placeholder, and reading it for hashing may download it.
- Delete a small reviewed batch first, confirm the remaining applications and files behave normally, and empty the Recycle Bin only when you are satisfied.
Frequently asked questions
- Does Windows 11 have a built-in duplicate-file finder?
- It has no general duplicate-removal screen. PowerShell can calculate and group full-content hashes, giving you a read-only exact-match report to review.
- Does the same SHA-256 hash prove files are duplicates?
- For practical duplicate-file checking, matching SHA-256 values calculated over the full contents provide strong proof that the files are byte-identical.
- Can PowerShell find similar photos?
- Not with Get-FileHash. Similar photos contain different bytes and need perceptual comparison, followed by a person choosing which frame to keep.