To remove malware, disconnect from the internet, stop signing in to accounts, update your security software, run a full scan with your built-in protection, uninstall apps and extensions you do not recognize, and run a second scan with a reputable free tool. Change passwords only after the device is clean.
Key takeaways
- Disconnect and stop signing in first, so the malware cannot steal more or spread.
- Built-in tools — Microsoft Defender, macOS XProtect and Google Play Protect — are the safest first scan.
- Change passwords only after the device is clean, or the malware may steal the new ones too.
Malware removal comes down to the same steps on any device: disconnect from the internet, stop signing in to accounts, update your security software, run a full scan, and uninstall any app or extension you do not recognize. Work through them in order — skipping ahead can undo your progress.
How do you know if you have malware?
The most common signs are sudden slowness, pop-ups that will not close, a changed browser homepage or search engine, new toolbars or extensions, programs you did not install, and friends receiving strange messages from your accounts. One sign alone may have an innocent cause; several together point to malware.
Also watch for battery drain on a phone, data usage that jumps for no reason, and security software that has been turned off without you touching it. If a pop-up claims your device is infected and offers to fix it, treat that pop-up itself as the malware: legitimate security software does not advertise through browser pop-ups. See our guide to how to know if your phone is hacked for the mobile warning signs in detail.
What should you do first if you have malware?
Do three things before you scan anything. First, disconnect from the internet: unplug Ethernet or turn off Wi-Fi, so the malware cannot send data out or download more. Second, stop signing in to accounts on that device, including shopping and banking sites.
Third, if this is a work or school device, stop and call IT. CISA's recovery guidance says to contact them immediately, because a quick response limits damage to your computer and to others on the network. Do not try to clean a work device yourself and hope nobody notices.
The FTC warns that scammers use fake security pop-ups to get remote access to your device and charge you for a problem that does not exist. If a pop-up or locked screen will not close, shut the device down, even if the message says not to.
How do you remove malware? The four-step method
Malware removal follows the same four-step path on every platform: update and scan, remove what you did not install, go deeper with a second scanner, and reset only as a last resort. Do the steps in order, and do not change passwords until the device is clean.
| Step | What to do | Windows | Mac | Android / iPhone |
|---|---|---|---|---|
| 1. Update and scan | Update OS, run a full scan | Microsoft Defender full scan | Update macOS, restart | Play Protect / update iOS |
| 2. Remove unknowns | Uninstall apps and extensions | Settings, Apps, Installed apps | Applications folder, Login Items | Safe mode, uninstall apps |
| 3. Second scan | Run a second-opinion scanner | Malwarebytes Free, offline scan | Malwarebytes Free for Mac | Malwarebytes for Android |
| 4. Reset (last resort) | Back up files, factory reset | Settings, Recovery, Reset PC | Erase All Content and Settings | Factory reset in Settings |
Safe Mode is the single most useful trick in this guide. It starts your computer with only the bare essentials, which stops most malware from loading and fighting back while you scan. On Windows, hold Shift and click Restart, then choose Troubleshoot, Advanced options, Startup Settings and Restart, and press 5 for Safe Mode with Networking.
How to get rid of malware on Windows
Windows includes Microsoft Defender Antivirus, so you do not need to buy anything to start. Update first, run a full scan, uninstall what you do not recognize, and finish with a Microsoft Defender offline scan, which reboots the machine and scans before Windows fully loads.
- Update first. Go to Start, then Settings, then Windows Update, and check for updates. If you are still on Windows 10, Microsoft ended support on October 14, 2025, so free security fixes have stopped — upgrade to Windows 11.
- Run a full scan. Open Windows Security, select Virus and threat protection, then Scan options, and start a full scan. Let it finish; it can take an hour or more on a large drive.
- Uninstall what you do not recognize. Go to Settings, Apps, then Installed apps, and sort by install date. Look closely at anything installed around the day the problems started.
- Check startup items. In Settings, Apps, Startup, turn off anything suspicious that launches when Windows starts.
- Run an offline scan. In the same Scan options list, choose Microsoft Defender Offline scan. It catches threats that hide during a normal session.
- Run a second scanner. Install the free version of Malwarebytes, update it, and run a full scan. Malwarebytes also offers a free rootkit scanner that checks for threats that hide deep in the system.
Quarantine is not the same as removal: after a scan, confirm that detected threats were removed or quarantined, and restart the computer before you use it normally again. CISA recommends keeping native antivirus and anti-malware protections active at all times, not just during cleanup.
How to get rid of malware on a Mac
Macs have built-in protection, but it runs on its own. Apple describes XProtect as antivirus technology that detects, blocks and removes known malware automatically, and its documentation does not describe a manual scan. Your job is mainly to update, restart and remove the source.
- Update macOS, or restart if you are current. Go to Apple menu, System Settings, General, Software Update. Apple says macOS includes a built-in tool that removes known malware when restarting.
- Check your Applications folder. Open Finder, select Applications, and look for apps you do not recognize. Drag unfamiliar apps to the Trash, then empty it.
- Remove suspicious login items. In System Settings, General, Login Items, remove anything suspicious that launches at startup.
- Check configuration profiles. In System Settings, Privacy and Security, Profiles, remove any profile you did not install yourself.
- Clean your browsers. Remove unknown extensions in Safari and Chrome, and reset your homepage and search engine.
- Run a second scan. Install Malwarebytes Free for Mac and run a full scan for a second opinion.
On Apple silicon Macs, Safe Mode works differently: shut the Mac down, press and hold the power button until startup options appear, select your drive, hold Shift, and click Continue in Safe Mode. For Intel Macs, restart and hold Shift until you see the login window.
How to remove malware from Android and iPhone?
On Android, use Google Play Protect and Safe Mode: update the phone, run a Play Protect scan, reboot into Safe Mode, and uninstall any app you do not recognize. On iPhone, update iOS, delete unknown apps and profiles, and restart — iPhones rarely get traditional malware, and the cause is usually a malicious profile or app.
For Android, open the Play Store, tap your profile icon, then Play Protect, and run a scan. Then press and hold the power button, long-press Power off, and tap Safe mode when prompted. In Safe Mode, third-party apps cannot run, so you can uninstall the suspicious one without it fighting back.
For iPhone, go to Settings, General, VPN and Device Management, and remove any profile you do not recognize. Then check Settings, Safari, and clear history and website data if pop-ups keep appearing. If problems persist after that, back up your photos and contacts and erase the phone. Our guide to how to secure your Wi-Fi also helps, because some phone infections start on a compromised network.
How do you clean browsers after malware?
Browser hijackers are the most common malware most people meet: a changed homepage, a new search engine, pop-ups on every site, or extensions you never installed. Cleaning the browser is a separate step from scanning the computer, and skipping it is why infections seem to come back.
- Remove unknown extensions in every browser you use, not just your main one.
- Reset the homepage and search engine to your usual choices.
- Clear cookies and cached data, which can store malicious redirects.
- Check notification permissions and revoke them for sites you do not recognize.
- Review saved passwords in the browser and remove any you do not recognize.
Do this after the scan, not before: if the malware is still running, it can reinstall the extension as fast as you remove it. If a browser keeps redirecting after a clean scan and a reset, uninstall and reinstall the browser itself.
What should you do after removing malware?
Only now — after the scans are clean and the unknown apps are gone — should you change passwords. Changing them earlier lets the malware steal the new ones too. Start with email, because it can reset every other account, then banking, then social media.
Check for new mail-forwarding rules and unknown MFA devices on your email account, and sign out of all sessions. Check whether any of your passwords appeared in a known breach with our free pwned password checker.
Then generate fresh, unique passwords for every important account with our free password generator, starting with email and banking.
When should you reset instead of cleaning?
Reset when the signs persist after two full scans, when the malware returns after removal, or when you cannot trust the machine with banking or work. A factory reset removes almost all malware, because it wipes the system and reinstalls the operating system.
Back up your files first — documents, photos and anything you cannot replace — but only restore files, not programs, from the backup. A program in the backup can carry the malware straight back. If you are unsure, a clean install from official media is safer than a reset that keeps your files.
How do you prevent malware coming back?
Prevention is mostly habits, not products. Keep your operating system and apps updated, keep native antivirus active, do not open attachments from unexpected senders, and do not download software from unofficial sites or pop-up ads.
- Update automatically — turn on automatic updates for the OS, browser and apps.
- Use a password manager so a phishing page cannot reuse a stolen password elsewhere.
- Turn on MFA for email and banking, preferably with passkeys or an authenticator app.
- Back up regularly to a drive you disconnect afterward, so ransomware cannot reach it.
- Be skeptical of pop-ups that claim your device is infected or that you have won something.
For a wider starting point, our small business cybersecurity checklist covers backups, updates and device security alongside malware defenses.
The bottom line
Malware removal is a process, not a single scan. Disconnect, stop signing in, scan with the built-in tools, remove what you did not install, and only then change your passwords from a clean device.
If the signs persist after two scans, back up your files and reset. And once you are clean, keep it that way: updates on, antivirus on, and a fresh password for every account, starting with email.
Frequently asked questions
How do I know if my computer has malware?
Common signs are sudden slowness, pop-ups that will not close, a changed browser homepage or search engine, new toolbars or extensions, programs you did not install, and friends receiving strange messages from your accounts.
Can I remove malware for free?
Yes. Microsoft Defender on Windows, XProtect on macOS and Play Protect on Android are free and built in, and the free version of Malwarebytes works as an on-demand second-opinion scanner. You do not need to buy anything to start.
Should I pay for malware removal?
No. Legitimate security companies do not call you about an infection, and pop-ups offering paid removal are usually the scam itself. Use the built-in tools and free scanners in this guide, and never give remote access to a stranger who contacts you.
How long does malware removal take?
A full scan can take from 30 minutes to several hours on a large drive. Plan for at least an hour for the first scan, plus time to remove suspicious apps, clean browsers and change passwords after the device is clean.
Will resetting my computer remove malware?
A factory reset removes almost all malware, because it wipes the system and reinstalls the operating system. It is a last resort, because it also deletes your files and apps, so back up your documents first and only restore files, not programs, from the backup.
Can malware come back after removal?
Yes, if the source is still there: a malicious browser extension, a compromised account, or a file you restore from backup. After removal, update everything, remove unknown extensions, and change passwords from a clean device.
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 guidance, Microsoft, Apple and Google support documentation, and Malwarebytes removal guidance.
How we write and fact-check →