bat Review (2026): Pricing, Features & Honest Verdict

Reviewed by MakerStack · Published · 3 min read

TLDR

bat is a cat replacement with syntax highlighting, line numbers, Git integration, and automatic paging. It makes reading code in the terminal genuinely pleasant. Best for: developers who read files in the terminal. Price: Free (open source). Rating: 8.1/10

What is bat?

bat is a drop-in replacement for the Unix cat command that adds syntax highlighting for over 200 languages, line numbers, Git diff markers, and automatic paging through less. Created by David Peter (the same developer behind fd), bat transforms terminal file viewing from plain text dumps into richly formatted, navigable output.

The tool detects file types automatically and applies appropriate syntax highlighting. It shows Git modifications in the gutter (added, modified, deleted lines), and when output exceeds your terminal height, it pages through less automatically. For developers who spend time reading code, configs, or logs in the terminal, bat is a significant quality-of-life improvement.

Key Features

Syntax Highlighting

bat supports 200+ languages and file formats out of the box using Sublime Text syntax definitions. The highlighting is accurate and fast, making code files immediately readable. Custom themes are supported too, so you can match your terminal color scheme.

Git Integration

The left gutter shows Git modification markers: green plus for added lines, yellow tilde for modified lines, red minus for deleted lines. This gives you instant diff context when reviewing files without running git diff separately.

Automatic Paging

When output is longer than your terminal, bat automatically pipes through a pager (less by default). When output fits the screen, it displays directly. This smart behavior means you never have to think about whether to pipe to less.

Line Numbers and Ranges

Line numbers are shown by default (togglable), and you can display specific line ranges with -r 30:50. This is useful for quickly viewing a specific function or section of a long file.

Concatenation Mode

When piping output to another command, bat automatically switches to plain mode (no highlighting, no line numbers) to avoid breaking downstream tools. This means you can alias cat to bat without breaking scripts.

Pricing

bat is free and open source under the MIT/Apache-2.0 dual license. Available via brew, apt, cargo, and all major package managers.

Pros and Cons

Pros

  • Syntax highlighting for 200+ languages makes code instantly readable
  • Git integration shows modification context in the gutter
  • Smart auto-paging adapts to output length
  • Drop-in cat replacement that works in pipes
  • Themeable with Sublime Text compatible themes

Cons

  • Slightly slower than plain cat for large files
  • Custom syntax definitions require specific format knowledge
  • Some terminal emulators don’t render themes correctly
  • Git gutter markers can be distracting when you don’t need them
PlanPricePlan FeaturesBest For
Open SourceFreeAll features, MIT/Apache-2.0Everyone

Who Should Use bat?

Every developer who reads files in the terminal. The switch is essentially free since bat works as a drop-in cat replacement. Alias cat to bat in your shell config and enjoy better output with zero behavior changes in scripts.

Alternatives

eza

A modern ls replacement with colors, icons, and Git status. bat and eza together transform your terminal file browsing experience.

highlight

A dedicated syntax highlighter that supports more output formats (HTML, LaTeX, RTF). More focused on highlighting than bat but lacks the cat-replacement convenience.

cat (GNU coreutils)

The original. Pre-installed everywhere, no dependencies, but no syntax highlighting, no line numbers, and no Git integration. Still needed for scripting.

FAQ

Should I alias cat to bat?

Yes. bat detects when it’s piping to another command and disables highlighting automatically, so aliases won’t break scripts.

How do I add custom syntax highlighting?

bat uses Sublime Text .sublime-syntax files. Place them in bat’s config directory and run bat cache --build.

Does bat slow down file viewing?

For typical code files, the delay is imperceptible. For very large files (100MB+), plain cat is faster, but you rarely cat files that large.

bat Pros & Cons

What We Like

  • Syntax highlighting for 200+ languages
  • Git integration shows modifications in gutter
  • Smart auto-paging adapts to output length
  • Drop-in cat replacement that works in pipes

What Could Be Better

  • Slightly slower than plain cat for large files
  • Custom syntax definitions require specific format
  • Some terminals render themes incorrectly

bat FAQ

Should I alias cat to bat?

Yes. bat detects piping and disables highlighting automatically so aliases work safely.

Does bat slow down file viewing?

For typical files the delay is imperceptible. Only very large files show a difference.

What is bat?

A cat replacement with syntax highlighting, line numbers, Git integration, and auto-paging. Makes reading code in the terminal beautiful.

How much does bat cost?

bat pricing starts at Free (open source). A free plan is available.

Is bat worth it?

bat is the easiest developer tool upgrade you can make. Alias cat to bat and enjoy syntax highlighting everywhere with zero downside. We rate it 8.1/10.

What are the best bat alternatives?

The top bat alternatives are eza, highlight and cat (GNU coreutils). Each is compared in the alternatives section of this review.

Disclosure: MakerStack is funded by featured placement fees, sponsor slots and a small number of affiliate links. Nobody paid for this review. Where any of those does apply to a review, we say so on the page. The scoring criteria are the same in every case. See our editorial policy.

This review describes bat as we tested it on March 21, 2026. Pricing, plans and features may have changed since. We don't update reviews on request; see our update policy.