Guides
How to verify a downloaded file with SHA-256 on Windows.
Check a download's SHA-256 with PowerShell Get-FileHash or certutil. What a match proves, what it doesn't, and why SmartScreen warns about some installers.
Key takeaways
- A SHA-256 checksum is a fingerprint of a file. If yours matches the publisher's, the file is byte-for-byte what they published.
- In PowerShell:
Get-FileHash .\file.exe -Algorithm SHA256. - A match proves the file was not corrupted or swapped, but only if you got the checksum from a trustworthy place.
- It is not the same as a code-signing certificate, which is what silences SmartScreen.
What a checksum is
A hash function turns any file into a short string of letters and numbers. Change a single byte of the file and the result changes completely. SHA-256 produces a 64-character hexadecimal string, and finding two different files with the same hash is, for practical purposes, impossible.
Publishers put the checksum of their installer on the download page. You compute the checksum of what you actually downloaded and compare. If they are identical, you have the real file.
Method 1: PowerShell
Open PowerShell in the folder with the file (in File Explorer, click the address bar, type powershell and press Enter), then run:
Get-FileHash .\TurboGet-Setup-0.2.4.exe -Algorithm SHA256
SHA-256 is the default algorithm, so Get-FileHash .\file.exe also works. The output has a Hash column. Compare it with the value on the website.
For TurboGet 0.2.4 the published value is 541fc4365a25ce06eac12ed29350585fba0aa45cc5f0fd2ed0f084d623855753.
Method 2: certutil (Command Prompt)
certutil -hashfile TurboGet-Setup-0.2.4.exe SHA256
This prints the hash on the second line. The comparison is the same.
Comparing safely
Do not compare by eye alone. Two hashes can look similar at the start and end but differ in the middle. Instead, paste both into a text editor and use search, or compare in PowerShell:
(Get-FileHash .\file.exe).Hash -eq "PASTE_PUBLISHED_HASH_HERE"
PowerShell compares hashes case-insensitively, so letter case does not matter. It returns True on a match.
What a match proves, and what it does not
It proves that your file is identical to the one whose hash was published. A broken download, a half-finished resume or a tampered file would all produce a different value.
It does not prove that the publisher is honest or that the software is safe. And it only helps if the checksum comes from a place an attacker could not also change. A hash shown on the same page as a malicious download would be changed with it. Prefer a hash published on the maker's own site, over HTTPS, or in a separate channel.
Why Windows still shows "Windows protected your PC"
SmartScreen is a reputation check. It warns about installers that are not signed with a paid code-signing certificate, or that are new and rarely downloaded. A matching checksum does not remove that warning, because the two mechanisms do different jobs:
- A checksum says this is the file the publisher released.
- A code signature says a verified identity signed it.
If the publisher is a solo developer without a certificate yet, as with TurboGet today, you click More info, then Run anyway, after you have verified the hash. I explain that choice openly in shipping an installer without a code-signing certificate.
When to verify
- Large installers from a small developer's site.
- Anything downloaded over an unreliable connection or resumed after a failure.
- Any tool you are about to give permission to install on your PC.
- ISO images of operating systems, where the publisher almost always lists hashes.
Frequently asked questions
Is SHA-256 better than MD5?
Yes. MD5 and SHA-1 have known weaknesses against deliberately crafted collisions. SHA-256 is the standard choice for checksums today.
My hash does not match. What now?
Download the file again, preferably from the official site, and check again. If it still differs, do not run it. A mismatch can come from a corrupted download or a changed file.
Does Windows have a graphical way to do this?
Not built in. PowerShell or certutil is the simplest route. Some third-party tools offer a right-click option.
TurboGet publishes the SHA-256 of its installer next to the download button.
See the checksum