For a syntax-highlighting pager for viewing code in the terminal, the strongest matches are sharkdp/bat (Bat is a drop-in replacement for cat and other), morhetz/gruvbox (Gruvbox is a color theme file, not a terminal) and shikijs/shiki (Shiki is a syntax highlighting engine that can produce). jakubonderka/php-console-highlighter and zsh-users/zsh-syntax-highlighting round out the shortlist. Each is ranked by relevance to your query, popularity and recent activity.
Command-line tools that render source code with syntax highlighting and navigation features for terminal environments.
This project is a command-line text viewer designed to enhance terminal output through automatic syntax highlighting and integrated file management. It functions as a replacement for standard system pagers, providing a readable interface for large text streams, source code, and markup files by applying color-coded formatting directly to the terminal output. The utility distinguishes itself through deep integration with version control systems, allowing users to inspect repository status and historical file changes with visual markers displayed in the output margin. It employs heuristic-based
Bat is a drop-in replacement for cat and other terminal pagers that adds syntax highlighting for dozens of languages, line numbers, automatic file-type detection, and customizable themes, fitting the search perfectly.
Gruvbox is a retro-inspired color scheme designed to provide a consistent visual experience across text editors, terminal emulators, and development environments. It focuses on improving readability and reducing eye strain by utilizing a high-contrast palette that remains stable across various software tools. The project distinguishes itself through a flexible rendering architecture that adapts to different technical environments. It supports high-fidelity twenty-four-bit color reproduction for modern terminals while maintaining compatibility with legacy systems through sixteen-color and two-
Gruvbox is a color theme file, not a terminal pager — it provides syntax highlighting color schemes for other tools but lacks any paging, file-type detection, or search capabilities.
Shiki is a syntax highlighting engine that generates color-coded HTML or ANSI output from source code. It functions as a static code highlighter, utilizing standard grammar definitions to parse text and apply accurate visual styling for documentation and terminal displays. The engine distinguishes itself by using a TextMate grammar parser to interpret text patterns, ensuring that code displays match the visual appearance of professional editors. It operates through an isomorphic runtime that supports both browser and server environments, utilizing WebAssembly for consistent execution and pre-
Shiki is a syntax highlighting engine that can produce ANSI output, but it is not a terminal pager itself—you would need to embed it into a pager to get the scrolling, search, and file navigation you are looking for.
PHP-Console-Highlighter is a syntax highlighter and console code formatter designed to apply color-coding to PHP source code for display in terminal environments. It functions as a utility to transform plain PHP text into visually structured code for command line interfaces. The tool enables terminal-based code review and provides formatted output for PHP static analysis tools and command line applications. It uses regex-based tokenization and ANSI sequence color mapping to translate syntax tokens into colored text.
It is a syntax highlighter for PHP code in the terminal, but it is not a pager—it lacks scrollable paging, search, and line number support, so it does not match the core functionality of a terminal-based pager with syntax highlighting.
zsh-syntax-highlighting is a Zsh shell extension and plugin that provides real-time syntax highlighting and visual feedback. It functions as an interactive command-line visual aid and regular expression text colorizer that distinguishes between commands, string literals, and shell constructs during input. The project allows for extensive customization through user-defined highlight rules, custom regular expression patterns, and predicate logic. It includes specific capabilities for path-based filtering and the assignment of custom colors to text segments. The system provides real-time comman
This is a Zsh plugin that highlights shell syntax as you type, not a terminal pager for viewing code files — it provides syntax highlighting in the wrong context (interactive command line, not file scrolling).
Rich is a comprehensive library for building sophisticated command-line interfaces and terminal applications. It provides a robust console formatting engine and a layout framework that enables developers to render rich text, syntax-highlighted code, and complex data structures directly in the terminal. By utilizing a recursive constraint-based layout engine, the library allows for the creation of hierarchical grids, panels, and trees that maintain their structure even as terminal dimensions change. What distinguishes the library is its ability to manage persistent, real-time terminal interfac
Rich is a library for formatting and syntax-highlighting terminal output, not a standalone pager—you would use it to build a pager, but it does not provide scrollable paging, file-type detection, or search themselves.
Nord is a cross-platform design palette and CSS color system providing a curated set of dimmed pastel colors for building consistent user interfaces and code themes. It functions as a UI design framework that delivers a standardized collection of colors through multiple file formats for use in development tools and graphic design software. The system is defined by its dual-mode visual theme, which coordinates complementary light and dark color sets to maintain a consistent visual hierarchy across different brightness modes. It also includes a syntax highlighting theme that maps specific palet
Nord is a color palette and syntax theme system for UI design, not a terminal pager — it can be used to theme such a pager, but it does not itself provide paging, file-type detection, or search, which is what this search requires.
jless is an interactive JSON explorer and command-line viewer designed for reading and navigating hierarchical data structures within a terminal. It functions as a terminal JSON formatter that pretty-prints data from files or standard input, including support for newline-delimited formats. The tool serves as a JSON path extractor, allowing users to identify and copy the dot or bracket notation paths from the root to specific nodes. It also includes a regex search utility for locating specific keys and values within JSON datasets using full-text regular expressions. The application provides c
jless is a terminal JSON explorer with syntax highlighting and paging, but it is specialized for JSON data only, not a general code-file pager that detects multiple programming languages.
wezterm is a terminal emulator, not a dedicated pager for viewing code files with syntax highlighting; it provides a terminal environment but lacks the pager-specific features like scrollable paging and file-type detection that a tool like bat or less would offer.
Kilo is a small-scale text editor implemented in C to demonstrate low-level systems programming. It provides a command line interface for modifying and saving text files directly within a terminal. The editor includes built-in string search and navigation capabilities to locate text within a file. It also applies colors to source code based on language patterns to provide syntax highlighting.
Kilo is a terminal text editor with syntax highlighting and search, but this visitor wants a dedicated pager for viewing (not editing) code files — a different category of tool.
Micro is a terminal-based text editor designed for use within command-line interfaces. It provides a keyboard-centric environment for creating and modifying source code and configuration files without requiring a graphical desktop system. The editor features a modular architecture centered on a plugin-driven system and an embedded scripting engine. Users can extend core functionality, automate workflows, and customize editor behavior by writing scripts or installing external extensions through a centralized package management system. This extensibility allows for the integration of custom com
Micro is a terminal-based text editor with syntax highlighting, not a dedicated pager for viewing files page-by-page, so it doesn't directly match the pager-focused search intent.
Kakoune is a scriptable, modal text editor for the terminal that employs a client-server architecture. This model allows multiple terminal windows to connect to a single editing session, providing a programmable environment for managing source code and text. The editor is distinguished by its selection-first logic, where a text region must be predefined before a command is applied. It leverages regular expressions to manage multiple cursors and perform bulk edits across complex text patterns, and it integrates deeply with the shell by piping selections through external programs and filters.
Kakoune is a terminal-based text editor with strong syntax highlighting and file navigation, which overlaps with paging, but its primary purpose is editing code rather than just paging through files, so it is adjacent to a dedicated syntax-highlighting terminal pager.
| Repository | Stars | Language | License | Last push |
|---|---|---|---|---|
| sharkdp/bat | 59.3K | Rust | Apache-2.0 | |
| morhetz/gruvbox | 15.2K | Vim Script | — | |
| shikijs/shiki | 12.9K | TypeScript | mit | |
| jakubonderka/php-console-highlighter | 6.2K | PHP | MIT | |
| zsh-users/zsh-syntax-highlighting | 22.7K | Shell | BSD-3-Clause | |
| textualize/rich | 56.6K | Python | MIT | |
| nordtheme/nord | 6.8K | SCSS | mit | |
| pauljuliusmartinez/jless | 5.4K | Rust | MIT | |
| wezterm/wezterm | 24.3K | Rust | other | |
| antirez/kilo | 8.8K | C | bsd-2-clause |