Viruses, malware, trojans, worms! These evil things can penetrate your computer through numerous ways like internet browsing, from USB devices, phishing links in your email and also by installing infected software.

Most of these viruses make your computer slow and eat up valuable memory as well as storage space. Some more powerful viruses are meant to contaminate our operating system too and steal personal information and banking data.

Also Read- Best Free Antivirus Software For Windows 10

The conventional method to identify and remove such unwanted programs from your computer is to install anti-virus software and scan your computer for any viruses/trojans/worms that exist and quarantine them.

However, there are some computer users out there who use unconventional methods to find such a virus and remove them without using any antivirus software.

Today we are discussing such an unconventional method by using Command Prompt or DOS Prompts to identify and remove viruses. 

Also Read- A-Z Windows CMD Commands List

The method is simple and straight which even a layman computer user can proceed with, just follow the steps given below :

Remove Computer Viruses Using CMD, without any antivirus

The Command Prompt or CMD/DIS Prompt is a command-line utility program on Windows 10.

Though the command prompt is rarely used by layman PC/laptop users, it is a powerful utility in the hands of pro hackers.

CMD has access to reconstruct all Windows system files by using various attributes like removing the hidden attributes which a virus normally uses.

One of the leading causes of virus infections in computers and the CMD method work on USB to remove its viruses and secure your computer.

Step 1. Click on Start and type cmd. Now right-click on the cmd icon and select run as administrator.

Running the command as administrator is important as you need to access the system files which are not usually visible in guest accounts.

Now command prompt window will open, now select your drive from which you want to remove a virus.

command prompt

Step 2. Let us suppose your USB has a virus and your USB drive is F. Type “F:” without quotation on Command line.

usb drive f

Step 3. Now the C: will change to F: Now you need to type “dir F:” in CMD and hit enter. It will show you the directory of the F drive.

directory f drive

Step 4.  So now type the following command to show all the hidden and system files on your USB drive. Type “dir F: attrib -s -h /s /d *.*”  without quotations and press enter. Typing this command will explore your selected drive and will load all the files including hidden and system files on your drive.

explore drive

Step 5. In this window, you will notice unusual file.exe  and extension if your computer has been infected with a virus like the dreaded autorun.inf virus.

Rename it using this command line rename filename.extension new filename. Usage > C://rename autorun.inf (new filename)

rename virus

That’s it!  Now you can identify all the viruses in your PC and USB and delete them without any help of anti-virus software. You can delete the autorun.inf by typing in the command “del autorun.inf” or del :”yourfilename”