34 Useful Keyboard Shortcuts for the Windows Command Prompt

cmds_top

Although you often use the Windows command prompt, you may be surprised at the number of useful keyboard shortcuts it supports. You can use them to simplify everything from selecting and manipulating text to repetitive commands you have already entered. And we have the complete list for you.

The command prompt is a powerful Windows tool that allows you to access all kinds of useful commands you can not get another way. By its very nature, the Windows command prompt is based on many keyboard uses, which are accompanied by convenient shortcuts. Most of these shortcuts exist since the beginning of the command prompt. Some are new to Windows 10 (especially those using the Ctrl key) and you will need to allow them before you can use them. When you're done, you're ready to unleash the fury of your keyboard.

Shortcuts to launch and close the command prompt

cmds_1

Windows actually offers a number of ways to open the command prompt. The following list shows some of the ways to open and close the command prompt only with your keyboard:

Windows (or Windows + R), then type "cmd": Run the command prompt in normal mode.
Win + X then press C: Run the command prompt in normal mode. (New in Windows 10)
Win + X then press A: Run the command prompt with administrator privileges. (New in Windows 10)
Alt + F4 (or type "exit" at the prompt): Close the command prompt.
Alt + Enter: Switches between full screen mode and windowed mode.

And even if one of these methods of opening the command prompt works, we recommend that you get used to open it with administrator privileges. Most of the interesting stuff you use will need it anyway.

Note: If you see PowerShell instead of Command Prompt in the Windows + X (Power Users) menu, it is a switch created with the Creator Update for Windows 10. It's very easy to Return to the Command Prompt Display in the Power Users Menu if you wish, or you can try PowerShell. You can do just about everything in PowerShell that you can do in the command prompt, as well as many other useful things.

Shortcuts to move

You can always click with your mouse to place the cursor anywhere in the command prompt. But if you want to keep your hands on the keys, we offer these shortcuts to move:

Home / End: Moves the insertion point to the beginning or end of the current line (respectively).
Ctrl + Left / Right Arrow: Moves the insertion point to the beginning of the previous word or the next word (respectively) on the current line.
Ctrl + up / down arrow: Scroll up or down without moving the insertion point.
Ctrl + M: Enter or exit the brand mode. In Marque mode, you can use the four arrow keys to move your cursor in the window. Note that you can still use the left and right arrow keys to move your insertion point to the left or right on the current line, whether the marker mode is on or off.

Once you have the habit of moving with the keyboard, you can even find it faster than moving to the mouse and vice versa.

Shortcuts to select text

cmds_2

Text being the motto of the command prompt, you will not be surprised to learn that there are many types of keyboard shortcuts for selecting text on the screen. Different shortcuts allow you to select text, a character, a word, a line, or even an entire screen at a time.

Ctrl + A: Selects all the text on the current line. Press Ctrl + A again to select all the text in the CMD buffer.
Shift + Left Arrow / Right Arrow: Extend the current selection of a character to the left or right.
Shift + Ctrl + Left Arrow / Right Arrow: Extends the current selection of a word to the left or right.
Shift + Up Arrow / Down Arrow: Extend the current selection of a line up or down. The selection extends to the same position in the previous or next line as the position of the insertion point in the current line.
Shift + Home: Extends the current selection at the beginning of an order. Press Shift + Home again to include the path (for example, C: Windows system32) in the selection.
Shift + End: Extend the current selection to the end of the current line.
Ctrl + Shift + Home / End: Extends the current selection at the beginning or end of the screen buffer (respectively).
Shift + Previous Page / Next Page: Extend the current selection of a page up or down.

It may seem like a lot to remember when you can simply select text with your mouse and, of course, the method that suits you best is the right way to do things. But we think that if you give yourself some time to get used to keyboard shortcuts, you may find that it's easier than using the mouse every time.

Shortcuts for manipulating text

cmds_3

Once you have selected text, it makes sense that you should be able to manipulate what you have selected. The following commands let you copy, paste, and delete selections quickly.

Ctrl + C (or Ctrl + Insert): Copy the currently selected text.
F2 and then a letter: Copy the text to the right of the insertion point to the letter you typed.
Ctrl + V (or Shift + Insert): Paste text from the clipboard.
Going back: Delete the character to the left of the insertion point.
Ctrl + Backspace: Delete the word to the left of the insertion point.
Tongue: Automatically complete a folder name.
Escape: Delete the current text line.
Insert: Switches to insert mode. When the insert mode is enabled, whatever you type is inserted at your current location. When it is off, whatever you type overwrites what already exists.
Ctrl + Home / End: Deletes the insertion point text at the beginning or end of the current line.
Ctrl + Z: Mark the end of a line. The text you type after this point on this line will be ignored.

Obviously, shortcuts for copy / paste are the most popular additions to Windows 10. Fortunately, you can use the others.

Shortcuts to use the order history

Finally, the command prompt keeps a history of all the commands you have entered since the beginning of your current session. It's easy to access previous commands and save a bit of typing.

F3: Repeat the previous command.
Up / down arrow: Scroll back and forth the previous commands you entered in the current session. You can also press F5 instead of the up arrow to scroll the command history backwards.
Right Arrow (or F1): Recreate the previous command character character by character.
F7: View the history of previous orders. You can use the up / down arrow keys to select a command, then press Enter to execute the command.
Alt + F7: Clear the command history.
F8: Go back in the command history with the commands corresponding to the current command. This is useful if you want to type a part of a command that you have used several times, then scroll through your history to find the exact command you want to repeat.
Ctrl + C: Abort the line being typed or a command running.

And that's about all. If you use the command prompt a lot, these keyboard shortcuts will be very useful for you to save time and avoid potentially erroneous commands. Even if you use the command prompt only occasionally, learning some basic shortcuts to get around more easily is well worth it.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.