• ARTICLES
SEARCH

How-To Geek

Keyboard Ninja: Scrolling the Windows Command Prompt With Only the Keyboard

The Windows command prompt (cmd.exe) has always been known for being underpowered compared to Linux, but have you ever noticed that to view the output of a long command you have to resort to the mouse to scroll?

You can easily scroll with just the keyboard, but to get into the “Scroll Mode” you’ll have to use a 4-key combination that reminds me of cheat codes on old nintendo games… Up, Up, Down, Down…

Press Alt+Space together, and then E, then L

image

This will put the command prompt into “Scroll” mode, where you can use the Page Up/Down keys as well as the arrow keys.

image

To get out of this mode, you can hit the Esc or Enter keys.

One of the most annoying instances of this problem is when trying to view the output of the ipconfig command… it always stretches beyond the current page on my system… now I can finally use the keyboard.

I love being a geek. =)

Lowell Heddings, better known online as the How-To Geek, spends all his free time bringing you fresh geekery on a daily basis. You can follow him on if you'd like.

  • Published 01/15/08

Comments (11)

  1. Russ Francis

    If you have Launchy installed, you may want to change its default hotkey (also Alt+Space) in order to take advantage of this tip.

  2. The Geek

    That’s a good point… I never liked the Launchy default, I use alt+space to minimize/maximize windows all the time.

  3. Nathan

    I never knew this, thanks for info, makes my life a hell of a lot easier ;)

    /Nathan

  4. spugbrap

    Thanks for the tip! I’m a die-hard keyboard/command-line user, and this could come in handy!

    One thing that’s unfortunate, though, is that once I’m scrolling via keyboard, I can’t select/copy/paste text with the keyboard. I’m guessing this is because I have Quick Edit enabled in the console window properties.

    I think I’ll just have to live with this one, though, because I have a feeling that even if I end up scrolling via keyboard some day, I’ll probably still end up falling back to the mouse for text selection/copy-to-clipboard functionality, and Quick Edit is a must for that.

    Don’t get me wrong, I select/copy/paste text via keyboard is most applications (like text editors, where hitting End will take me to the end of the line), but I think in a console window it would probably be more trouble than it’s worth (since it would have no awareness of the contents of the lines, it would just be copying 2d arrays of characters).

  5. The Geek

    spugbrap:

    The keyboard text selection in the command prompt leaves much to be desired… it’s much simpler to use the mouse for that.

    I’m also a die-hard keyboard guy… but if I can accomplish something quicker by using the mouse I usually resort to it.

    I’ve been thinking, it would be interesting to hook up an autohotkey script to automate the hitting of the 4 keys whenever you hit Page Up the first time… shouldn’t be too difficult.

  6. Planet Lowyat

    Cool! It may useful somehow sometimes.

  7. Tyson

    Nice tip! Another way to accomplish the same thing without using the menus is to just end your commands with “|more” this way the output from your command stays on one screen until you press enter to get the next line of text.

    Example

    ipconfig/all |more

    Have a nice day.

  8. min

    fantastic – I’ve been meaning to get round to working out how to do this for ages, nice post, thanks very much

  9. bill

    Thanks, but in my case scroll was not active.

    Tyson’s trick was what I was looking for. Like I used to use /p to see page by page.

  10. Tagnu

    Thanks for the tip.

  11. al

    thanks!

Get Free Articles in Your Inbox!

Join 134,000 newsletter readers

Email:

Go check your email!