Syntax Highlighting Packages
Source-code syntax-highlighting libraries for rendering readable, colorized code blocks in docs, editors, and blogs (Shiki, Prism, highlight.js).
Packages in Syntax Highlighting
Kind
Sort:Used by Most Apps
Shiki
A syntax highlighter that renders code with the exact TextMate grammars and themes VS Code uses.
highlight.js
Zero-dependency JavaScript syntax highlighter with automatic language detection for over 190 languages.
@codemirror/language
Language support infrastructure for the CodeMirror 6 editor: parsing, indentation, code folding, bracket matching, and syntax highlighting.
React Syntax Highlighter
A React component for syntax-highlighting code blocks using highlight.js or Prism ASTs, with JavaScript-based styles and no external stylesheet required.
prism-react-renderer
A lightweight, themeable Prism syntax highlighter for React and React Native, built on a render-props API.
rich
A Python library for rendering rich text, tables, progress bars, and syntax-highlighted code in the terminal.
lang-javascript
JavaScript, TypeScript, and JSX language support for the CodeMirror 6 code editor.
@lezer/highlight
Syntax highlighting framework that maps Lezer parse trees to styleable highlighting tags
Prism
Lightweight, extensible syntax highlighting for the web and Node.js, with support for 300+ languages.
lowlight
Virtual syntax highlighting for virtual DOMs and non-HTML things, powered by highlight.js
Fumadocs Core
The headless React library for building documentation websites, with source loading, page trees, MDX processing, search, and i18n.
@codemirror/lang-sql
SQL language support for the CodeMirror editor: parsing, syntax highlighting, and schema-aware autocomplete across multiple SQL dialects.
@codemirror/lang-python
Python language support for the CodeMirror code editor, with highlighting, indentation, and autocompletion.
Pygments
Generic syntax highlighter for Python supporting over 500 languages and formats
rehype-highlight
Rehype plugin that syntax-highlights code blocks at build time using lowlight and highlight.js.
Ace Builds
Prebuilt Ace code editor bundles for embedding a fast, extensible editor with 100+ language modes in any web app
tree-sitter-typescript
TypeScript and TSX grammars for the tree-sitter incremental parsing framework.
tree-sitter-python
A fast, incremental Python grammar for the tree-sitter parsing library
tree-sitter-javascript
JavaScript and JSX grammar for the tree-sitter incremental parsing library
@codemirror/lang-rust
Rust language support for the CodeMirror 6 code editor, powered by a Lezer grammar.
tree-sitter-rust
A fast, incremental Rust grammar for the tree-sitter parsing library
tree-sitter-cpp
A fast, incremental C++ grammar for the tree-sitter parsing library
tree-sitter-go
A fast, incremental Go grammar for the tree-sitter parsing library
diff2html
Generate pretty, GitHub-style HTML diffs from git diff or unified diff output