PowerShell: Run a Full Windows Defender Scan
Need to trigger a full malware scan covering every file on all drives - as part of a script, scheduled task, or thorough manual check? This one-liner starts it directly from the terminal.
Prerequisites:
- Privileges: None
- Module: Built-in, no import needed
Quick Command:
Start-MpScan -ScanType FullScan
📦
Want all of them at once?
Get every free one-liner from this blog in a single downloadable bundle organized by category, each with full comment-based help. No more copy-pasting one at a time.
Get every free one-liner from this blog in a single downloadable bundle organized by category, each with full comment-based help. No more copy-pasting one at a time.
How It Works:
- Start-MpScan triggers a Windows Defender scan directly through PowerShell, without needing to open the Windows Security GUI.
- -ScanType FullScan specifies a full scan - checking every file across all drives, rather than just the common malware locations covered by a quick scan.