If you’re a new Linux user trying to navigate the lines of inputs and outputs filling your terminal, it might be a bit overwhelming. Because recent lines remain visible, as your inputs increase and your outputs grow longer, your screen can quickly grow unrecognizable, buried in a wall of white text. When you don’t need this previous information, you can always clear the terminal, but what if you realize later that you’ve lost something important? Maybe you’re troubleshooting an issue, or looking to repeat a previously entered command. Regardless of why, if you’re looking for how to scroll up and down in the Linux terminal, then read on to learn several methods for easily navigating the Linux terminal using your keyboard.
How to Scroll Up and Down in Linux
As with many things in Linux, the ability to scroll up and down within your terminal depends on the specific terminal you are using. For most users, you should be able to scroll up and down, one line at a time using Shift+UpArrow or Shift+DownArrow. To jump an entire page at a time, try Shift+PageUp or Shift+PageDown.
If these commands don’t work, it’s likely your terminal is using different keybindings. While determining exactly which keyboard shortcuts work for your terminal requires you to know which terminal you’re running, there is a secondary method which is quite common as well. The other common method for moving up and down a line at a time involves using Ctrl+Shift+UpArrow or Ctrl+Shift+DownArrow. This same alternate pattern can be used to jump whole pages at a time using Ctrl+Shift+PageUp or Ctrl+Shift+PageDown.
Keep in mind, some terminals don’t allow scrolling at all, or only keep a very limited history of previous inputs. These options may be modifiable from within the terminal’s configuration file, but this will depend entirely on the terminal being used.
Some terminals also offer a designated “scroll mode,” allowing users to easily navigate using the arrow keys when active. To see if this is something your terminal offers, try hitting the Scroll Lock key on your keyboard. If your keyboard does not have a designated Scroll Lock key, try using the command Ctrl+A. This activates scrollback mode on GNU Screen, allowing users to move through the terminal easily using the keyboard. Whether or not this option is available to you is entirely dependent on the specific terminal you are running.
*Note: To exit scroll mode, simply hit the Esc key at any time.
And there you have it! Depending on your terminal, one of these methods may work better than the others, but for most instances, you can scroll up in the Linux terminal using either Shift+PageUp or Ctrl+Shift+PageUp.
For more information on Linux, check out the links below or search our Knowledge Base for more useful tips and tricks for Linux novices and veterans alike.
- How to Check the Apache Version on a Linux Dedicated cPanel Server
- How to Change a Password in Linux
- How to Check if Your Linux Server is Under DDoS Attack
Don’t see what you’re looking for? Use the search bar at the top to search our entire Knowledge Base.
The Hivelocity Difference
With best-in-class customer service, affordable pricing, a wide-range of fully-customizable options, and a network like no other, Hivelocity is the hosting solution you’ve been waiting for.