Working on the Command Prompt can fill up your screen with text very quickly. This is a pet peeve of a lot of people. Luckily, clearing the screen while working on CMD is a very easy task. You can use a dedicated command, a keyboard shortcut, or simply open a new tab to get rid of the text on the screen. Here are the top 4 ways to clear the Windows Command Prompt screen.
Read Also: Top 8 ways to fix ‘WhatsApp images not showing in gallery’
Which method is best for you?
There are 4 broad ways of clearing the screen on CMD:
- CLS command
- Ctrl + L keyboard shortcut
- Opening a new tab
- Restarting CMD
The CLS command is perhaps the easiest, most accessible way to clear the CMD screen. This is the method we recommend the most. It works in every scenario and gets the job done with ease. However, if you don’t want to let go of the text on the screen but want a fresh screen to begin a new task, you should open a new tab. This brings more organisation to the screen without losing the history of previous commands.
When you restart CMD, it always opens on a fresh screen. This does the trick too, but it is not something we recommend when you’re actively occupied with a task. What you can do is use the ‘start’ command to open a new CMD window without letting go of the previous one.
Use the CLS command
Step 1: Click the search box in the taskbar and look up Command Prompt.
Step 2: Launch the Command Prompt app.
Step 3: Type cls and hit Enter.
Use the keyboard shortcut
Not many people know this but there is a handy keyboard shortcut to clear the Windows Command Prompt screen. When the Command Prompt screen is active on your PC, press Ctrl + L to clear it.
Open a new tab
If there’s a lot of activity on your current Command Prompt, you can open a new tab to begin working on a fresh screen. This method comes in handy when you are working on something important and don’t want to clear your history of commands. To open a new tab, hit the plus icon on the title bar.
Close and restart Command Prompt
When you restart Command Prompt, it always opens with a fresh screen. Type ‘exit’ and hit Enter to close the app. Use the search box in the taskbar to open it again. You can also close Command Prompt by clicking the cross icon in the title bar of the program.
Bonus Tip: How to view and save Command Prompt history?
If you want to take a look at the commands you have used in the current sessions, press F7. Follow the steps mentioned below to save the command history.
Step 1: Type doskey /history > history.txt and hit Enter.
Step 2: Click the search box in the taskbar and enter ‘history.txt’. This will open the list of all the commands you have used.
Frequently Asked Questions (FAQs)
What is the CLS command in CMD?
The CLS command clears the Command Prompt screen.
How do I clear the Command Prompt screen?
You can clear the Command Prompt screen by using the CLS command or Ctrl + L keyboard shortcut.
What is the ‘clean’ command in CMD?
The ‘clean’ or ‘erase’ command clears the data and partitions of the current drive.
How do I clear a line in CMD?
Hitting the Esc key once clears the current line of text in Command Prompt.
How to run the cleanup command on CMD?
Open CMD, type cleanmgr /[name of the drive], and hit Enter.
Read Also: Apple May Bring Heart Rate to Next-Gen AirPods Pro 3
Final Thoughts
These are the best methods to clear the screen on Command Prompt. While you’re here check out how you can run Command Prompt as an administrator in Windows 11. If you have any other questions, let us know in the comments!