How To Clear Command Prompt History In Windows 10

0 Comments
Editor Ratings:
User Ratings:
[Total: 0 Average: 0]




This tutorial explains how to clear Command Prompt history in Windows 10. I have covered many different ways to delete command prompt history. For example, one method clears all history that is stored in background and can be visible by pressing F7 hotkey. And another method clears previous as well as new commands from Command Prompt history. Go through each of these and see which one you like the most.

You can easily view and save Command Prompt history and when you think you need to clear this history to have new commands in buffer, then you can try any of the methods covered in this tutorial. Although Command Prompt history is cleared automatically as soon as you close the window, but when some work is already going on and you don’t want to close Command Prompt, then these methods will be handy.

Let’s start with the first method to clear Command Prompt history in Windows 10.

Method 1: Clear Command Prompt History In Windows 10 Using A Hotkey

This is the easiest method to clear Command Prompt history in Windows 10. Just a single hotkey will clear all the command history. You have to press “Alt+F7” hotkey to clear entire Command Prompt history. It clears the history that can be viewed by F7 hotkey or Up and Down arrow keys. It doesn’t give any warning or prompt you if you want to clear the entire Command Prompt history. So you need to be careful before using this hotkey.

Method 2: Clear Command Prompt History In Windows 10 Using A Simple Command

This is another simple method to delete all the previous commands you have typed in Command Prompt. However, this method is more powerful and it automatically clears every single command that you will execute in the current session. So instead of just clearing the previous commands, this method clears all the next commands that you will execute. So there will be no record of any command. Also, when you want to keep commands, you need to close Command Prompt window and start the new session.

To clear history of previous commands as well as new commands using this method, you need to type “doskey /listsize=0” and press Enter.

enter and execute command

Once you have done this, previous command history would be deleted, and any new command that you type will not be added to history.

Method 3: Clear Command Prompt History In Windows 10 using One Word Command

Another method to clear Command Prompt history in Windows 10 is by executing a one word command. However, this command works in a different way. Instead of removing history from background (F7 and Up and Down arrow keys), it simply clears the Command Prompt window. So whatever you have executed is cleared by this command. However, you will be able to access commands using F7 hotkey and Up and Down arrow keys. So, if you want to clear all commands from Command Prompt interface only, then this method is very useful for you.

To clear Command Prompt history using this method, enter “cls” command and execute.

enter cls command

This will clear the whole Command Prompt window so you won’t be able to see previously executed commands directly on its interface.

The Verdict:

So these are some really simple methods using which you can clear Command Prompt history in your Windows 10 PC. I prefer method 1 which is simplest and best for me.

Editor Ratings:
User Ratings:
[Total: 0 Average: 0]

Leave A Reply

 

Get 100 GB FREE

Provide details to get this offer