10 Brilliant Command Prompt (CMD) Tricks You Probably Don’t Know About

Ads by Google


While talking about the 15 amazing Run Box commands the other day, I mentioned how both Run Box and Command Prompt are treated as a bit nerdy. Well, one might work on Windows without even touching the Run box but you cannot run away from Command Prompt (cmd). No matter how good Windows may evolve on the GUI front, Command Prompt (or more accurately, the Command Line ) was how it all began.

So here are some great tips you can use to make yourself comfortable while working with the Command Prompt. First things first, the shortcut for Command Prompt is cmd and that’s all you need to type in the Run box or the Start search in order to bring it up. Now on to the cool tricks, which might be known ones for the geeky ones among you, but on the other hand, have the potential to incite the a-ha moment for many other everyday computer users among you.

Let’s roll, shall we?

1. Open Command Prompt in a Folder

When you open the command prompt, it opens up in either User or System folder depending upon whether you ran it as administrator or not. Now the thing is, if you want to execute a file in any particular folder, you would have to use the change directory(cd) command to navigate to the folder which can be a problem if the directory is nested way too deep.


To ease things you can open the folder in your Windows Explorer, hold Shift key when you right-click in the folder and select Run command window here  to directly open the CMD prompt with the path to that folder directly.

2. Enable QuickEdit for Easy Copy/Paste

One thing I miss the most in Command Prompt is the ability to easily copy and paste text using the conventional Windows hotkeys. Normally, one would have to use the right-click context menu options to copy and paste text, but if you enable QuickEdit, you can do them using simple shortcuts.


To enable the QuickEdit mode, right-click on the Command Prompt Title Bar and select Properties. In the Properties Window under the Option Tab enable QuickEdit Mode. That’s all; you can now quickly select text by dragging your mouse pointer. Pressing the enter key on the selected text will copy the text to the clipboard, and a simple left click would be enough to paste the text.

3. Run Command Prompt as Admin

Many commands require you to run command prompt as administrator. When you search for CMD in Start Menu, other than selecting Run as administrator from the right-click menu, you can simply press Ctrl+Shift+Enter to open it with admin privileges. This trick will work for all the programs installed on your system.

4. See Command History

You can see last used commands in a session using the navigation buttons, but if you would like to see a list of all the commands, you can get it by pressing the F7 button.


Alternatively, you can use the command doskey /history  to list these commands in the command prompt itself.

Ads by Google

doskey history

5. Change Command Prompt Looks

white CMD

Are you bored with the conventional black-and-white looks of the command prompt and would like to paint it different? We have already covered a guide on how you can customize your command prompt which you can refer to make the changes.

6. Copy Commands Output to Clipboard Directly

Sometimes one might want to copy the output from a command to clipboard, like at times when you get an error, and you want to paste the exact error in email or while chatting with someone.

To store a command output to a clipboard add the command | clip at the end of the command. For e.g. Dir /p | clip

7. Drag and Drop Files to Change Path

If you are already in command prompt, and you want to copy the exact path to a folder or file to run the file or change the present working directory, you can simply drag and drop the file or the folder on the command prompt.

The path of the dropped file or folder will show up in quotes.

8. Run Commands Simultaneously

You can put && between two commands and execute them one after another. The command on the left will execute first followed by the command on the right of the double ampersand.

9. Get Help for Command


Well let’s say you know about a command, but you are not sure how it works. Not a problem, all you need to do is suffix the command with /?  and execute it. If the command is valid, the command prompt will give you all the information related to it.

10. Watch Star Wars in ASCII

star wars

For all my nerdy friends who are diehard fans of Star Wars, you can actually watch the Star Wars Episode IV movie in the command prompt. Though it would be in ASCII, it will be fun. To start the movie, open command prompt, type in telnet towel.blinkenlights.nl. and press enter. Don’t forget the popcorns though :)

Bonus Tips: Also check how to find computer name using Command Prompt and the IP Address of a domain using a particular command.


I am sure these tricks will make you a little more comfortable with the Windows Command Prompt. If you are one of our more tech savvy readers who has been relying on the Command Prompt for years, why not share some cool tricks that you’ve got up your sleeve? Chip in with your comments!

Get Guiding Tech articles delivered to your inbox.

We will never share your address. Unsubscribe at any time.

  • http://www.facebook.com/ashishpatel.1992 Ashish Patel

    i knew except starwars

  • BosseWeb

    Starwarstip does not seem to work im my swedish Win7 64-bit

    • http://www.techpanache.com/ Ashish Mundhra

      I too am running Windows 7 64-Bit and the screenshot is taken in the machine itself. Please make sure you include the last period(.) in the command. Some people miss it.

      • Niks

        I took it. Still not working. It says “telnet” is not recognized as an internal or external command, operable program or batch file.

        • http://www.techpanache.com/ Ashish Mundhra

          Make sure Telnet Client feature is activated on your system.
          You can activate it from Turn Windows Feature on or off from the add/remove programs in Control Panel

          • Noah

            Telnet connects to remote servers. The remote serve removed the star wars video.

            • Noah

              Never mind I just found out it worked.

            • jkid12345

              no it didnt you dumbass

          • Beeshal

            thanks dude it really works…

        • http://www.funbutlearn.com/ FunButLearn

          Telnet is by default disabled. You have to manually make it enabled as Ashish mentioned below.

        • xerman2005

          Telnet may be Disabled, go to your Control Panel, Programs And Features, Turn Windows Features On And Off, then check Telnet Client, now try it!

          (P.S If you check Telnet Server it will run a Telnet server, which some people wont want so if you don’t want other computers to be able to connect to your computer then don’t enable it.)

      • Tysean Tutson

        but its still blank on my screen what do i do??

  • http://www.geekandblogger.com/ Pavan Somu

    Something cool and exiting. Liked :)

  • Pingback: 10 Awesome Things To Do With Command Prompt :: TinyHacker()

  • Gaurav Kumar

    Another exciting one- right click on the cmd window on the taskbar (shift + right click on windows 7) > Edit > Find
    There you have it…a nice find dialogue so that you can directly have a search in the cmd window.

  • http://www.funbutlearn.com/ FunButLearn

    I am writing a book called “What else you can do with command prompt”. When I will publish it I will let all of you know about it.
    Anyway you missed another useful command which is required when you run multiple commands simultaneously. For multiple commands you can use &&
    Another one is use >> to copy the output to a notepad directly.

  • http://www.facebook.com/ajush.psnath Ajush P S Nath

    dat star wars thing is not workin for me i hav tried evrytin..still gets nly a blank cmd screen..

    • htr

      ajush p s nath if you want it to work go to control panel go to programs click on the runand shutdown windows programs and click on that scroll down until you see telnet enable it and wait do the steps again in cmd and you got it steps first type telnet then type o then type towel.blinkenlights.nl and your good to go

  • Wise Geek

    Display a Message containing the reason for shutdown
    Type shutdown -s -t 60 -c “I am tired. I don’t want to work anymore.” (with the quotes) in the Command Prompt and press Enter. The -c switch is used in the code to give the reason for shutting down and what is followed in quotes will be displayed in the dialogue box as the reason. This can be used to display all sorts of funny messages and can be edited if you want to. The -t is the time it will take to shut down in this case it will be 60 seconds. This can be edited aswell. :) Enjoy!

    • Me


      • XxHULKxX

        EASIER WAY! :
        Type in “shutdown -i”
        Then it will open up a window asking u what u want to do and the message u want to display 😛 Have fun

  • fewfeww

    the starwars isn’t working

    • Yaakov

      Are you using windows 7? If so go to control panel/programs and features on the left side of the screen there should be a link saying turn windows features on or off click it scroll down and check the boxes telnet client and server then try again :)

      • Tysean Tutson

        but its still blank on my screen what do i do???

        • garry

          use windows xp the movie is great

          • Benji OYET

            its awesome , it worked on my windows 7 ultimate, just follow #Yaakov’s instruction.

    • jkid

      you have to use telnet not command prompt

      • Myself

        u can open it through cmd it uses the telnet “proxy” im not sure how to word it

    • nils yoyo

      just open youtube and type star wars by cmd on windows 7…… watch the vedio and have this _|_

    • sr

      you should have internet connection for that

    • Dibyashubhro Roy
    • ehtfdglf

      did you activate telnet

    • Helo

      Well duh it’s made out of 8’s

    • Summer

      Its not -tears-

      • Summer

        Thank you Yaakov!

    • me


  • http://twitter.com/KCalpha Kasey Moore

    He’s a good one. Write in ‘If you’re happy and you know it, Syntax Error!’

  • jamesiswizardone

    thanks for this.,.its a great help

  • Shantonu Mandal

    The Drag and Drop functionality to get the path of a file/folder does not work in Admin mode on Windows 8. Any workaround/setting I might have to set?

    • bdaniel230

      get win 7 or wait till win 9 comes out?

  • Guest
  • Kartik Sharma
  • Kartik Sharma
  • Hemant Baluja

    its great star wars on cmd thanks for cool tip can u tell me the command for saving username and passwords

  • awesomeguy

    for the starwars thing you have to go in to the control panel in the “disable/enable windows features” menu and enable telnet server and telnet client.

  • http://funwidtricks.com/ Vinay

    Nice, all are interesting.. thanks for sharing

  • louie

    can i ask for help?? how can i hack administrators password???thanksss.

    • bdaniel230

      It will work the same as abuser names unless it is a corporate edition. If so you don’t want to hack it unless you have another job lined up.



  • impinball

    On 8, there should only be one ampersand unless you need the first to not fail for the second. One ampersand simply let’s you run two commands in sequence automatically on the same line. Two ampersands runs the previous command, checks if it ran successfully (i.e. an errorlevel of 0), and if the last command was successful, run the command after the double ampersand. The functionality described above should only have one ampersand, not two.

  • hacker


  • Guest

    Dude………. the star wars thing is pretty a

  • rishi

    i can break windows password without any tool…

    • Hamza


      safe mode with command promote??

      • guy

        just type –
        net user USERNAME_HERE *
        The start is nessecery(Shift+8) with a space after the username

  • rishi
  • Dinhanh

    Dinhs mom was awesome last night <3



  • http://unique-trick.blogspot.com Mohit Verma

    Make a Virus that could eject your optical media continuously and automatically and also get to know more command prompt tricks @http://goo.gl/8JPGnl

  • bdaniel230

    who did the conversion of starwars to ascii? We have been rolling around my cube laughing for an hour, great work!

  • HELO

    Star wars isn’t working correctly :( A FAKE I can tell you made it on your keyboard with 8’s I’m not 2. I know I spelled hello wrong >.<

    • duh

      do you know whats ascii is

  • baraza moses

    how do you transfer the cmd on the notepad to the cmd prompt

    • chris

      save it as .bat file

  • Toshan


  • hi

    star wars still isn’t wiorking

  • wtf

    star wars wont work!!

  • wtf


  • Bonda

    Hahaha..don’t ever enable telnet client, this makes hackers life too easy!

  • Colin Morgan

    Well done. Thanks.
    Can you tell me away to be a fake hacker with command prompt.?