How to Completely Remove a Trojan, Virus, Worm or Other Malware
To remove malware, disconnect the computer from the internet, back up your personal files (not programs), and run a full offline scan with Microsoft Defender Offline, which starts before Windows loads so malware cannot hide. Follow with a second-opinion scan such as Microsoft Safety Scanner, review startup programs with Sysinternals Autoruns, and update Windows and all apps.
Topic: Cyber Threats, Scams & Online Safety in Cybersecurity & Ethical Hacking · Tutorial
Quick answer: To remove malware, disconnect the computer from the internet, back up your personal files (not programs), and run a full offline scan with Microsoft Defender Offline, which starts before Windows loads so malware cannot hide. Follow with a second-opinion scan such as Microsoft Safety Scanner, review startup programs with Sysinternals Autoruns, and update Windows and all apps. Then change your important passwords from a different, clean device and turn on multi-factor authentication. If infection persists, or it is ransomware, a rootkit or a banking trojan, the only fully reliable fix is to reset or reinstall the operating system.
Key takeaways
- Disconnect first to stop data theft and spreading.
- Offline scanning catches malware that hides while Windows is running.
- Assume passwords used on the infected device are stolen.
- A clean reinstall is the only guaranteed removal for serious infections.
- Back up documents and photos, never executables, before cleaning.
Table of Contents
- How Do You Know a Computer Is Infected?
- Do Trojans, Viruses and Worms Need Different Removal?
- What Are the Removal Steps on Windows?
- How Do You Check for Leftover Startup Entries?
- When Should You Reset or Reinstall?
- What About macOS and Android?
- What Should You Do After Cleaning?
- What Should a Business Do Differently?
- References
How Do You Know a Computer Is Infected?
- Security software disabled or unable to update.
- New browser extensions, changed home page or constant pop-ups.
- Unknown programs at startup, high CPU or network use when idle.
- Friends receive messages you did not send; accounts show unknown logins.
- Files renamed or encrypted with a ransom note (ransomware).
Do Trojans, Viruses and Worms Need Different Removal?
| Type | How it spreads | Removal notes |
|---|---|---|
| Trojan | Disguised as legitimate software | Often installs backdoors; change all passwords |
| Virus | Attaches to files | Infected files may need restoring from backup |
| Worm | Spreads over networks by itself | Isolate the device; check others on the network |
| Rootkit | Hides deep in the system | Offline scan or reinstall |
| Ransomware | Encrypts files | Isolate, report, restore from backup; reinstall |
The basic procedure is the same for all; the difference is how much you must clean up afterwards. NIST SP 800-83 describes malware incident handling for organisations.
What Are the Removal Steps on Windows?
- Disconnect Wi-Fi and Ethernet.
- Back up documents and photos to an external drive. Do not copy programs or downloads.
- Run Defender Offline: Windows Security, Virus and threat protection, Scan options, Microsoft Defender Offline scan. The PC restarts and scans.
- Get a second opinion with Microsoft Safety Scanner, downloaded on a clean device if needed.
- Remove unknown programs and browser extensions.
- Update Windows, browsers and all applications.
# Start a full Defender scan from an administrator PowerShell window
Start-MpScan -ScanType FullScan
# Start an offline scan (the PC will restart)
Start-MpWDOScan
# See what Defender found
Get-MpThreatDetection | Select-Object ThreatID, ActionSuccess, Resources
How Do You Check for Leftover Startup Entries?
Autoruns from Microsoft Sysinternals lists everything that starts automatically. Use Options, Hide Microsoft Entries, then look for unsigned entries in odd folders such as AppData or Temp. Untick suspicious entries rather than deleting them, so you can undo a mistake.
When Should You Reset or Reinstall?
- The infection returns after cleaning.
- Scanners report a rootkit or cannot remove a threat.
- It is ransomware or a remote access trojan.
- The device is used for banking or work and you cannot be sure it is clean.
Use Windows' "Reset this PC" with "Remove everything", or a clean reinstall from Microsoft's media as described in Microsoft's reinstall guide. Scan your backups before restoring them.
What About macOS and Android?
macOS includes XProtect, which detects and removes known malware automatically (Apple Platform Security). Remove unknown apps, login items and profiles in System Settings, and update macOS. On Android, boot into safe mode, uninstall suspicious apps, revoke Device Admin and Accessibility access for unknown apps, and run Google Play Protect; factory reset if problems continue. CERT-In's Cyber Swachhta Kendra lists free cleaning tools for Indian users.
What Should You Do After Cleaning?
- Change passwords for email, banking and social accounts from a clean device.
- Turn on multi-factor authentication.
- Check bank statements and email forwarding rules.
- Keep automatic updates and real-time protection on.
- Report fraud at cybercrime.gov.in or call 1930 in India.
Related: protecting your data from ransomware and avoiding phishing emails. WebAsha offers malware analysis training.
What Should a Business Do Differently?
On a company device, do not clean it yourself. Report to IT or the security team, because the infection may be part of a wider intrusion.
- Isolate the device using EDR network containment rather than wiping it straight away.
- Collect evidence: alerts, memory and disk images where needed.
- Check other devices for the same indicators.
- Reset the user's credentials and revoke sessions.
- Rebuild from a known-good image.
- Report to CERT-In within six hours if the incident is a reportable type.
NIST SP 800-61 Rev. 3 describes incident response for organisations, and CISA's StopRansomware site has ransomware-specific guidance.
References
Frequently Asked Questions
What's Your Reaction?
Like
0
Dislike
0
Love
0
Funny
0
Wow
0
Sad
0
Angry
0