Skip to content
Agents tracked: 506 Releases (7d): 634 Agent status: 3 with issuesSince last limit reset: Claude 15d · Codex 0d For AI agents: Markdown Updated Nov 26, 2026

rehype-pretty-code

Syntax highlighting plugin for rehype to render beautiful code blocks in Markdown/MDX.

Markdown, editors and contentNPM

GitHubWebsite

1. License

License from npm.

github.com/rehype-pretty/rehype-pretty-code

From the package registry and GitHub, checked daily. Tap a verdict to see its source.How we checkedReport an error

What rehype-pretty-code does

Syntax highlighting plugin for rehype to render beautiful code blocks in Markdown/MDX.

rehype-pretty-code popularity

46 / 100
Gid Score, #2474 overall
959K
downloads a week, npm
1,317
GitHub stars
17
agent projects use it
rehype-pretty-code: downloads per weeknpm, rehype-pretty-code 959,343
rehype-pretty-code: GitHub starsrehype-pretty/rehype-pretty-code 1,317

Gid Score measures public popularity and activity, not quality. How the Gid Score is calculated

How rehype-pretty-code is used

  • rehype-pretty-code is a dependency in 17 of the 6,258 public GitHub projects set up for AI coding agents that we scanned, too few to describe it from them alone. Our scan also samples projects by dependency (Solana 3,067, Ethereum and EVM 1,774, 3D and games 3,130, agent frameworks and SDKs 13,750); counting those, it appears in 39 projects, and what it is used with below comes from all of them.
  • The most used alternative in our scan is Shiki (85 projects).
  • Projects that use it most often also use Next.js (89.7%), Shiki (79.5%), clsx (76.9%).

By coding agent

13 projects, 0.4%
8 projects, 0.3%

Often used with

In 89.7% of its projects
In 79.5% of its projects
In 76.9% of its projects
In 76.9% of its projects
In 76.9% of its projects
In 76.9% of its projects
In 94.9% of its projects
In 92.3% of its projects

More about rehype-pretty-code

More in Markdown, editors and content

Alternatives

rehype-pretty-code This page

MITGid 46959K/wk

Shiki

Beautiful syntax highlighter powered by TextMate grammars with superior accuracy.

MITGid 7642.6M/wk

highlight.js

Syntax highlighting library with automatic language detection for code blocks.

BSD-3-ClauseGid 7758.1M/wk

React Syntax Highlighter

React component for syntax highlighting code with Prism.js or Highlight.js.

MITGid 659.9M/wk

Compare rehype-pretty-code with another tool

Get started

Install it.

npm install rehype-pretty-code

No step-by-step start for rehype-pretty-code yet: we have not written its hand-checked card.