Cmd Command: How to Open Command Prompt Fast
In this article
To open Command Prompt with the keyboard, press Windows key + R, type cmd, and press Enter. That is the fastest universal method on Windows 10 and 11. You can also press Windows key, type cmd, and press Enter; or use Ctrl + Shift + Enter after typing cmd in the Start menu to open it as administrator. The steps below cover these methods, how to run commands as admin, and what to do when the window will not open or a command fails.
What You'll Need
- A Windows 10 or Windows 11 PC with a keyboard.
- Permission to open Command Prompt. Standard accounts can open it, but administrator-level commands require an administrator account or the administrator password.
- No extra software. Command Prompt is built into Windows.
Menu labels and shortcut behavior can differ slightly by Windows version, edition, and region. The steps below are written for the standard Windows 10 and Windows 11 desktop.
Step-by-Step
- Open the Run box. Press Windows key + R at the same time. A small Run window appears in the lower-left corner of the screen.
- Type the command. Type
cmdinto the Open field. Do not add spaces or quotes. - Press Enter. Command Prompt opens in a new window. The prompt usually shows your user folder path and ends with a greater-than sign (
>). - Run a command as administrator (optional). If you need admin rights, close the window and repeat the steps, but this time press Ctrl + Shift + Enter after typing
cmdin the Run box or Start menu search. Windows shows a User Account Control prompt; select Yes. The window title will include Administrator. - Type a command and press Enter. For example, type
ipconfigand press Enter to see your network configuration. Commands are not case-sensitive. - Close Command Prompt safely. Type
exitand press Enter, or click the X in the top-right corner. Closing the window ends the session; any command still running stops.
If you prefer the Start menu: press the Windows key, type cmd, and press Enter. To open as administrator from there, right-click the Command Prompt result and choose Run as administrator, or highlight it and press Ctrl + Shift + Enter.
Common Mistakes
- Typing
cmdinto the wrong place. Typing it into a browser address bar or a document does nothing. Use the Run box or Start menu search. - Forgetting administrator rights. Many commands fail with "Access is denied" if the window is not elevated. Check the window title for Administrator before assuming the command is broken.
- Running commands in the wrong folder. Some commands act on the current directory. Use
cdto change folders, or provide a full path, before running file-related commands. - Closing the window mid-command. Closing Command Prompt stops the running command and can leave a task incomplete. Wait for the prompt to return before closing.
- Confusing Command Prompt with PowerShell. Both are command-line tools, but some commands and syntax differ. If a command is not recognized, check that you are in Command Prompt, not PowerShell.
Tips
- Use the address bar shortcut. In File Explorer, click the address bar, type
cmd, and press Enter to open Command Prompt in that folder. This saves typing long paths. - Pin it for later. After opening Command Prompt, right-click its taskbar icon and choose Pin to taskbar so you can open it with one click next time.
- Use Tab completion. When typing file or folder names, press Tab to cycle through matching names in the current folder.
- Copy and paste. Right-click inside the window to paste. To copy, select text and press Ctrl + C, or right-click and choose Mark to select text.
- Check before you run. Commands can change files or settings. If you do not understand a command, look it up before pressing Enter.
Troubleshooting
If Command Prompt does not open or a command fails, work through these checks in order.
- Restart the PC. A restart clears temporary glitches that can stop the Run box or Start menu from responding.
- Try the other opening method. If Windows key + R does nothing, press the Windows key, type
cmd, and press Enter. If that also fails, open Task Manager with Ctrl + Shift + Esc, choose File > Run new task, typecmd, and press Enter. - Check for the administrator prompt. If a command returns "Access is denied," close the window and reopen it with Ctrl + Shift + Enter from the Run box or Start menu, then approve the User Account Control prompt.
- Look at the error text. "Not recognized as an internal or external command" usually means a typo or that the tool is not installed. Check the spelling and confirm the program exists.
- Sign out and back in. If the Start menu search cannot find Command Prompt, sign out of Windows and sign back in. This reloads the user shell.
- Check policy restrictions. On a work or school PC, an administrator may have blocked Command Prompt. Contact your IT administrator; do not try to bypass the restriction.
Do not delete system files or run commands from untrusted sources to fix a simple opening problem. If the issue persists after a restart and sign-out, use Windows Settings to check for updates, or contact Microsoft support.
Frequently Asked Questions
What is the keyboard shortcut to open Command Prompt?
Press Windows key + R, type cmd, and press Enter. For administrator mode, press Ctrl + Shift + Enter instead of Enter.
Can I open Command Prompt without a mouse?
Yes. Use Windows key + R or the Windows key to open search, type cmd, and press Enter. Use Tab and the arrow keys to move through results if needed.
How do I run Command Prompt as administrator?
Type cmd in the Run box or Start menu, then press Ctrl + Shift + Enter and approve the User Account Control prompt. The window title will show Administrator.
Why does Command Prompt open and close immediately?
This usually happens when a command is set to run on startup or a shortcut is misconfigured. Open Command Prompt from the Run box or Start menu instead of a shortcut, and check startup apps in Task Manager.
Is Command Prompt the same as PowerShell?
No. They are separate tools with different syntax. Some commands work in both, but many do not. If a command is not recognized, confirm which window you are using.
Can I use Command Prompt on a Mac?
No. Command Prompt is a Windows tool. macOS uses Terminal, which accepts different commands. The steps here apply to Windows 10 and Windows 11 only.