The fastest way to remove malware depends on what kind you have

If your computer is running slowly, showing pop-up ads, or behaving strangely, malware may be the cause. The steps to remove it differ based on whether you can still start your computer normally, whether you use Windows or Mac, and whether the malware is actively blocking your tools.

The most direct approach is to run a dedicated malware scanner while your computer is in Safe Mode — a stripped-down version of Windows or Mac that loads only essential programs. This prevents the malware from interfering with the scan. If your computer won't start at all, you may need to use a bootable scanner on a USB drive created from another device.

For most people, the process takes 30 minutes to two hours depending on how much malware is present and how large your hard drive is.

Key Takeaways

  • Safe Mode prevents malware from running while you scan, making removal more likely to succeed on the first attempt.
  • Malwarebytes and Windows Defender are the two most common free tools; Malwarebytes is stronger for stubborn infections, while Windows Defender is built into Windows.
  • If your computer won't start normally, create a bootable USB scanner on another device and boot from that instead.
  • After removal, change your passwords from a different device, then change them again once you are confident the malware is gone.
  • Restarting your computer after removal is essential — malware often stays in memory until you reboot.

How to remove malware on Windows using Safe Mode

Start by restarting your computer and entering Safe Mode before the malware has a chance to load. On Windows 10 and 11, hold the Shift key while clicking the restart button in the Start menu. On older Windows versions, restart and press F8 repeatedly as the computer boots until you see the Advanced Boot Options menu, then select Safe Mode with Networking.

Once in Safe Mode, download Malwarebytes from another computer if you cannot reach the website, or use Windows Defender if Malwarebytes will not install. Windows Defender is built into Windows 10 and 11 — open Settings, go to Privacy & Security, then Virus & Threat Protection, and click Scan Options to choose a Full Scan. Malwarebytes is free to download from malwarebytes.com and offers a more aggressive scan for stubborn infections.

Run the full scan and let it complete without interrupting. This can take 30 minutes to two hours depending on your hard drive size. When the scan finishes, review the results and remove all detected items. Restart your computer normally — malware often stays active in memory until you reboot, so this step is essential.

How to remove malware on Mac

Mac malware is less common than Windows malware, but it does exist. The most reliable free tool is Malwarebytes for Mac, available at malwarebytes.com. Download it, install it, and run a full scan. Mac does not have a Safe Mode equivalent that prevents third-party software from running, so a standard full scan is usually sufficient.

If Malwarebytes finds nothing but your Mac is still behaving strangely, restart in Recovery Mode by restarting and holding Command+R until the Apple logo appears. Open Disk Utility and run First Aid on your main drive to check for file system errors, which can sometimes mimic malware symptoms. If problems persist after that, the issue may be a browser extension rather than system malware — check your browser's extension list and remove anything unfamiliar.

What to do if your computer won't start normally

If your computer will not boot into Windows or Mac at all, you need a bootable scanner on a USB drive. Use another computer to create this. On Windows, download the Malwarebytes Rescue Disk ISO file from malwarebytes.com, then use a tool like Rufus (rufus.ie) to write it to a USB drive. On Mac, download the Malwarebytes Bootable USB tool from the same site and follow the instructions to create the drive.

Insert the USB drive into the infected computer, restart it, and press the boot menu key — usually F12, Esc, or Del depending on your computer's manufacturer. Select the USB drive from the menu. The scanner will load from the USB and run without the malware interfering. Let the full scan complete, remove all detected items, and restart normally.

If you cannot access the boot menu or the computer will not recognize the USB drive, you may need to take the computer to a repair shop. This is not common, but it happens when malware has modified the BIOS or firmware.

Removing browser malware and unwanted extensions

Some malware lives only in your web browser as extensions or hijacked settings rather than infecting your whole system. Signs include a changed homepage, a new search engine you did not install, or constant pop-up ads even after a full system scan.

In Chrome, Firefox, Safari, or Edge, open Settings or Preferences, go to Extensions, and remove anything you do not recognize or remember installing. Then check your homepage and search engine settings — they should be set to your preferred options, not something unfamiliar. Clear your browser cache and cookies by going to Settings, Privacy, and selecting Clear Browsing Data.

If a search engine or homepage keeps resetting itself after you change it, malware may be reinstalling it. In that case, run another full system scan with Malwarebytes or Windows Defender, restart your computer, and try changing the settings again.

Protecting your passwords after malware removal

Malware often captures passwords and login information while it is running. After you remove it, change your passwords — but do this from a different device first. Use your phone, tablet, or another computer to change passwords for email, banking, social media, and any other important accounts. This way, if malware is still present on your main computer, it cannot intercept the new passwords as you type them.

Once you are confident the malware is gone — usually after running a second scan a few days later — change your passwords again from your main computer. This ensures that even if malware captured your first new password, the second one is secure.

If you use a password manager like Bitwarden, 1Password, or LastPass, change that password first, then use it to update all your other passwords at once. This is faster and more secure than changing each one individually.

Preventing malware in the future

Most malware enters through email attachments, fake download sites, or compromised websites. Keep Windows or Mac updated by turning on automatic updates in Settings. Use an ad blocker in your browser — uBlock Origin is free and blocks many malware-serving ads. Do not open email attachments from people you do not know, and be cautious of attachments even from people you do know if the message seems unusual.

Download software only from official websites or the Microsoft Store and Mac App Store. Avoid torrent sites and file-sharing services, which are common sources of malware. If a website asks you to install a plugin or update to view content, close the tab instead — legitimate updates come through your system settings, not random websites.

Windows Defender or Mac's built-in security is usually enough for everyday use. You do not need to pay for antivirus software unless you frequently download files from untrusted sources.

Frequently Asked Questions

Can I remove malware without restarting my computer?

Restarting is strongly recommended because malware stays active in your computer's memory until you reboot. A scan may find and remove the malware files, but the running malware process can interfere with the removal or restart itself. Always restart after a scan completes.

What if Malwarebytes and Windows Defender find nothing but my computer is still slow?

Slowness can come from a full hard drive, too many startup programs, or a failing hard drive — not always malware. Check your hard drive space in Settings, disable unnecessary startup programs, and run Disk Utility on Mac or Check Disk on Windows to look for errors. If those do not help, a hardware issue may be the cause.

Is it safe to use my computer while a malware scan is running?

It is safe but not recommended. Scans take longer if you are using the computer at the same time, and you may accidentally interfere with the scan. Let it run uninterrupted in the background if possible.

Do I need to reinstall Windows or Mac if malware won't go away?

Reinstalling is a last resort, not a first step. Try Malwarebytes, Windows Defender, and a bootable scanner first. If none of those work, the malware is unusually stubborn, and reinstalling your operating system will remove it completely — but you will lose your files unless you back them up first.

Can malware on my computer infect my phone or tablet?

Most computer malware cannot directly infect phones or tablets because they run different operating systems. However, if malware captured your passwords on your computer, it could use those to log into accounts on your phone. This is why changing passwords from a different device is important.