To remove ransomware, disconnect the infected device from the network, photograph the ransom note, identify the strain with ID Ransomware or No More Ransom, report it to the FBI at ic3.gov, remove the malware with a trusted scanner or by rebuilding the system, and restore your files from a clean offline backup. Do not pay the ransom unless you have no other option and have taken legal advice.
Key takeaways
- Isolate first: disconnect the device from the network, but leave it powered on unless you cannot disconnect it.
- Identify the strain before you clean anything — a free decryptor exists for some families, and wiping destroys that chance.
- Restore only from a clean offline backup on a rebuilt system, and reset every password after the system is clean.
A ransom note on your screen means your files are encrypted and a timer is running. The worst thing you can do now is panic-click: paying, wiping or reconnecting the device can destroy your only chance of getting files back. Follow the order below instead.
What is ransomware, and how does it work?
Ransomware is malware that encrypts your files and demands payment, usually in cryptocurrency, for the decryption key. Many strains also steal your data first and threaten to publish it.
It usually arrives by phishing email, a malicious download, an exposed remote-access service, or a compromised account. Once inside, it can spread to shared drives, backups and other computers on the same network before it shows the ransom note. CISA's ransomware response checklist sets out the order to follow.
That spread is why the first step is always isolation, not cleanup. CISA's #StopRansomware Guide, updated in May 2023 and written jointly by CISA, the FBI, the NSA and the Multi-State Information Sharing and Analysis Center, sets out the same order used in this guide: detect, isolate, report, contain, eradicate and recover.
How do you know you have ransomware?
You have ransomware if files suddenly have a strange new extension, will not open, or are replaced by a ransom note demanding payment for a decryption key.
Other signs include a flood of renamed files, a new desktop wallpaper with payment instructions, disabled security software, and shadow copies or backups that have been deleted. Some strains also lock the whole screen instead of encrypting files one by one.
If you see any of these signs, treat it as ransomware even if you are not sure yet. The steps below are safe for a false alarm and essential for a real attack. For the wider pattern of how these attacks start, see our guide to what spear phishing is.
How do you remove ransomware step by step?
Isolate, document, identify, report, remove, then restore. Do not skip ahead to wiping or restoring, because each earlier step protects the later ones.
Step 1: Isolate the infected device
Unplug the network cable, turn off Wi-Fi and Bluetooth, and disconnect USB drives, external disks and network shares. If several systems are affected, take the network offline at the switch level.
Leave the device powered on if you can disconnect it. CISA notes that powering down destroys evidence stored in memory, so only power down if you cannot disconnect the device from the network any other way.
Use out-of-band communication, such as phone calls, to coordinate the response. Attackers may monitor your email or chat to see whether they have been detected.
Step 2: Document what you see
Photograph the ransom note with your phone. Write down the new file extension, any email address, website or payment address in the note, and the time you first saw it.
Do not delete the ransom note or rename encrypted files. Both are needed to identify the strain and to report the attack. Keep a copy of the note and one sample encrypted file on a separate, clean USB drive if you can do so safely.
Step 3: Identify the ransomware strain
Use ID Ransomware or the Crypto Sheriff tool on No More Ransom. Upload the ransom note and a sample encrypted file, and the tool will name the family and tell you whether a free decryptor exists.
ID Ransomware currently detects 1,192 ransomware variants. No More Ransom lists more than 160 free decryption tools covering roughly 200 families, built by police, national agencies and security vendors.
Identification matters because a decryptor only works for its own family and often only for specific versions. Running the wrong tool wastes time and can damage files further.
Step 4: Report the attack
In the US, report to the FBI at ic3.gov or to your local FBI field office, and consider contacting CISA. Businesses should also call their IT provider and their cyber insurer before they do anything else.
Reporting helps law enforcement track the group, warn other victims and, in some cases, share a decryptor recovered from a seized server. The FBI has recovered keys this way for families including Hive, GandCrab and REvil.
If personal data was stolen as well as encrypted, talk to a lawyer about breach notification duties. Those deadlines run from discovery, not from recovery.
Step 5: Remove the ransomware
Run a full scan with an up-to-date security tool: Microsoft Defender on Windows, including a Microsoft Defender Offline scan, or a reputable scanner on a Mac. Remove everything it finds, then scan again.
For a business network, or if the scanner finds a backdoor, a rootkit or signs of lateral movement, do not trust a scan alone. Rebuild the system from known-clean media or a standard image, as CISA recommends, and do not restore data until the system is clean.
Check for the tricks ransomware uses to block recovery: deleted shadow copies, disabled backups, new administrator accounts, and scheduled tasks or services you do not recognize. CISA specifically warns to look for misuse of tools such as vssadmin, wbadmin and bcdedit.
Step 6: Restore from a clean backup
Restore only from an offline, encrypted backup that was made before the attack and has been checked for infection. Do not connect your backup drive to the infected device to check it.
CISA warns that many ransomware variants try to find and encrypt accessible backups. That is why the 3-2-1 rule matters: three copies of important files, on two different types of media, with one copy offline or off-site.
Restore in priority order: the systems your business needs first, then everything else. Monitor restored systems closely for reinfection, and do not reconnect them to the main network until they have been scanned.
How do you remove ransomware on Windows?
On Windows, isolate first, then run a Microsoft Defender Offline scan. Open Windows Security, go to Virus and threat protection, choose Scan options, select Microsoft Defender Offline scan, and select Scan now.
The offline scan restarts the computer and scans before Windows fully loads, which catches malware that hides while Windows is running. After it finishes, run a full scan as well, then check for new accounts, new scheduled tasks and disabled backup settings.
If Defender finds a persistent threat, or if files keep getting encrypted after a clean scan, rebuild the computer from clean installation media. That is faster and safer than chasing a backdoor you cannot see. Reset every password after the rebuild, starting with email and administrator accounts.
How do you remove ransomware on a Mac?
On a Mac, disconnect from the network, then check Activity Monitor for unknown processes and remove unknown login items and browser extensions. Run a full scan with a reputable Mac security tool.
Mac ransomware is rarer than Windows ransomware, but it exists, and Macs are often hit by the same phishing and remote-access tricks. Do not assume a Mac is clean because the ransom note looks like a Windows one.
If the Mac still behaves strangely after a scan, back up only known-clean personal files to a separate drive, erase the Mac, reinstall macOS from recovery, and restore only those files. Change your Apple ID password and check for unknown devices on your account.
Can you decrypt your files for free?
Sometimes. A free decryptor exists only when researchers found a flaw in the ransomware's encryption, or when police seized the attackers' keys. For most modern strains, no decryptor exists.
No More Ransom is the safest place to check. It was launched in 2016 by Europol, the Dutch National Police, Kaspersky and McAfee, and its decryption tools page lists free tools by family, each with a guide from its maker. Download decryptors only from No More Ransom or the named maker's own site — never from a search ad or a video description.
Before you try a decryptor, remove the malware first, work on copies of your files rather than the originals, and keep the encrypted originals safe. No More Ransom warns that ransomware still running will lock files again after you decrypt them. Our guide to securing your Wi-Fi covers one of the common entry points attackers use to reach home networks.
| Recovery option | When it works | What to do |
|---|---|---|
| Free decryptor | Your strain has a known flaw or seized keys | Check No More Ransom, test on copies |
| Clean offline backup | Backup was made before the attack and was offline | Rebuild, then restore in priority order |
| Shadow copies | Ransomware did not delete them | Check before you rebuild; many strains delete them |
| Paying the ransom | Last resort only, with legal advice | No guarantee; funds further attacks |
| No backup, no decryptor | Modern strain, no flaw found | Keep encrypted files safe; check again later |
Should you pay the ransom?
CISA and the FBI advise against paying. Payment does not guarantee your files back, it marks you as a payer for future attacks, and it can create legal risk if the attackers are on a sanctions list.
There are cases where victims pay because the data is irreplaceable and no backup exists. If you are in that position, do not decide alone: talk to your insurer, your lawyer and law enforcement first, and let a professional negotiator handle the contact if one is available.
Even if you pay, assume the attackers kept a copy of your data. Change every password, rebuild affected systems, and treat the incident as a breach, not just an encryption event.
What mistakes make ransomware recovery worse?
The most common mistakes are reconnecting the device too soon, restoring from a backup that was connected during the attack, and wiping before identifying the strain.
- Reconnecting too soon. A device that still has a backdoor will re-encrypt restored files and spread to clean systems.
- Trusting a connected backup. If the backup drive was plugged in during the attack, assume it is encrypted too until you prove otherwise.
- Wiping before identification. You lose the chance of a free decryptor and the evidence law enforcement needs.
- Paying without advice. You may pay a sanctioned group, or pay for a key that does not work.
- Forgetting passwords. Attackers often steal credentials before encrypting. Reset every password after the system is clean, not before.
How do you prevent ransomware next time?
Prevention is cheaper than recovery. The controls that stop most ransomware are boring, well-known and often skipped: offline backups, patched software, phishing-resistant MFA and limited remote access.
- Keep offline, encrypted backups and test them. A backup that was connected during the attack is not a backup.
- Patch promptly, especially VPNs, remote access and email servers. These are the entry points ransomware groups exploit most.
- Use phishing-resistant MFA. CISA recommends FIDO security keys or passkeys, especially for email and remote access.
- Limit remote access. Close RDP to the internet, use a VPN with MFA, and disable accounts that no longer need access.
- Train staff on phishing. Most ransomware still starts with a clicked link or attachment. Test with our free phishing quiz.
- Segment your network. If one computer is infected, it should not be able to reach every server and backup.
Use strong, unique passwords for every account after a reset. Our password generator can create them.
The bottom line
Ransomware recovery is a sequence, not a single tool: isolate, document, identify, report, remove, then restore from a clean backup. Skip a step and you risk losing the files, the evidence or the clean systems around the infected one.
Put the prevention in place before the next attack, starting with offline backups you have actually tested. You can check whether your old passwords were already exposed with the free pwned password checker.
Frequently asked questions
Can ransomware be removed?
Yes, the malware itself can be removed with a trusted scanner or by rebuilding the system. Removing the malware does not decrypt your files, though. For that you need a free decryptor for your strain, or a clean backup.
Should I pay the ransom?
CISA and the FBI advise against paying. Payment does not guarantee your files back, it funds further attacks, and it can create legal risk if the attackers are sanctioned. Talk to your insurer and a lawyer before you consider it.
Can I remove ransomware for free?
Yes, in many cases. Microsoft Defender on Windows, a reputable free scanner, and free decryptors from No More Ransom can remove the malware and, for some strains, decrypt files. Professional help is still worth it for a business network.
Will resetting my computer remove ransomware?
A full reset or clean reinstall from known-clean media usually removes the malware, but it also deletes your files unless you restore them from backup. Do not reset until you have identified the strain and preserved evidence.
How do I know which ransomware infected me?
Use ID Ransomware or the Crypto Sheriff tool on No More Ransom. Upload the ransom note and a sample encrypted file, and the tool will name the family and tell you whether a free decryptor exists.
Can ransomware spread to other computers?
Yes. Many strains spread across a local network, shared drives and cloud folders. That is why CISA tells you to isolate infected systems immediately and to take the network offline at the switch level if several systems are affected.
How long does ransomware recovery take?
A single home computer can take a few hours if you have a clean backup. A business network can take days or weeks, because every system must be checked, rebuilt and monitored for reinfection before it reconnects.
Sources
The engineers and analysts who build Cysoro's domain scanner, email-authentication checks and free security tools. We test what we write about every day — SPF, DKIM, DMARC, certificates, look-alike domains and phishing — and check each guide against the relevant standards, government guidance and vendor documentation.
Checked against CISA's #StopRansomware Guide and Ransomware Response Checklist, the No More Ransom project, and FBI IC3 reporting guidance.
How we write and fact-check →