more Command
Beginner Text Processing man(1)View file contents one screen at a time
👁 8 views
📅 Updated: Mar 15, 2026
SYNTAX
more [OPTION] [FILE]
What Does more Do?
The more command is a simple file viewer that displays text one screenful at a time. It is the predecessor to less, offering basic forward pagination through files and piped output.
more allows you to scroll forward through a file, search forward for patterns, and jump to specific positions. However, unlike less, it does not support backward scrolling on most implementations.
While less has largely replaced more for interactive use, more remains useful in minimal environments (like recovery consoles), in scripts where simple pagination is needed, and as a quick way to page through short command outputs.
more allows you to scroll forward through a file, search forward for patterns, and jump to specific positions. However, unlike less, it does not support backward scrolling on most implementations.
While less has largely replaced more for interactive use, more remains useful in minimal environments (like recovery consoles), in scripts where simple pagination is needed, and as a quick way to page through short command outputs.
Options & Flags
| Option | Description | Example |
|---|---|---|
| -d | Display help prompt instead of bell on invalid input | more -d file.txt |
| -f | Count logical rather than screen lines | more -f wide.txt |
| -p | Clear screen before displaying each page | more -p file.txt |
| -s | Squeeze multiple blank lines into one | more -s document.txt |
| -n | Display N lines per screenful | more -20 file.txt |
| +/pattern | Start display at first occurrence of pattern | more +/ERROR logfile.txt |
Practical Examples
#1 Page through a file
Displays the file one screen at a time. Press Space to advance.
$ more /etc/services#2 Start at a pattern
Opens the file scrolled to the first line matching "ssh".
$ more +/ssh /etc/services#3 Page through command output
Paginates a long directory listing for easy reading.
$ ls -la /usr/bin | more#4 Squeeze blank lines
Compresses multiple consecutive blank lines into a single blank line.
$ more -s document.txt#5 Start at specific line
Starts displaying from line 100.
$ more +100 largefile.txt#6 View file with prompts
Shows [Press space to continue, q to quit] prompts instead of just a percentage.
$ more -d logfile.txtTips & Best Practices
Navigation keys: Space = next page, Enter = next line, b = back one page (some implementations), /pattern = search, q = quit.
Use less instead: In most situations, less is superior to more. It supports backward scrolling, better search, and does not read the entire file into memory.
No backward scroll in pipes: When more receives piped input, backward scrolling is not possible even in implementations that support it for files.
Frequently Asked Questions
What is the difference between more and less?
less supports backward scrolling, pattern searching in both directions, and does not need to read the entire file. more only scrolls forward and is more limited. less is the recommended choice.
How do I quit more?
Press q to quit. If q does not work, try pressing Ctrl+C or :q.
Why use more instead of less?
more is available on virtually all Unix systems including minimal installations and recovery environments. Use it when less is not available.
Related Commands
More Text Processing Commands
Master Linux with Professional eBooks
Curated IT eBooks covering Linux, DevOps, Cloud, and more
Browse Books →