ipython-pygments-lexers
Defines a variety of Pygments lexers for highlighting IPython code.
Decision gist · record as of 2026-08-14
Yes, if you need to highlight IPython code or sessions. The package is lightweight, has no known vulnerabilities, and fills a specific niche that standard Python lexers don't cover. Install it when you're building documentation, educational tools, or anything that displays IPython code and wants proper syntax coloring for magics and shell commands.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires pygments to be installed; Python >=3.8
- Low friction install with a single runtime dependency on pygments.
- Maintenance status is aging—last commit was 2025-12-15, but the package is recent (first released 2025-01-15) and the repository remains active and not archived.
License · maintenance · safety
permissive license (permissive) — Licensed under BSD (permissive), so you can use, modify, and distribute the package with minimal legal restrictions.
last release 2025-01-17 (574 days) · last repo commit 2025-12-15
0 known vulnerabilities (OSV.dev, 2026-08-14) · 78,556,467 downloads/mo, #435 on PyPI
Alternatives
Verify before relying
pip install ipython-pygments-lexers
from pygments.lexers import get_lexer_by_name
lexer = get_lexer_by_name('ipythonconsole')- Whether the lexers handle all current IPython syntax features and special forms reliably
- Performance characteristics when highlighting large IPython session transcripts
What it is and what it does
This package provides Pygments lexers specifically designed to highlight IPython code and interactive sessions. IPython adds special syntax—like `%magics`, `!shell commands`, and `help?`—that standard Python lexers don't recognize. ipython-pygments-lexers fills that gap with two main lexers: one for highlighting IPython input code alone, and another for full IPython console sessions including prompts, output, and tracebacks. The lexers were previously bundled inside IPython itself but have been extracted into a standalone package to keep concerns separate and make them easier to maintain and reuse in other tools.
The package depends only on pygments, making it lightweight to install. It's aimed at developers and documentation tools that need to display or highlight IPython code snippets with proper syntax awareness. If you're building documentation, notebooks, or any tool that renders IPython sessions, this lexer set lets you highlight them correctly.
Use it for
- Highlight IPython code snippets in Sphinx documentation or static site generators
- Display IPython console sessions in tutorials or blog posts with proper syntax coloring
- Syntax-highlight IPython input in code review or analysis tools
- Render IPython transcripts in educational platforms
- Add IPython-aware syntax highlighting to terminal-based code viewers
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you need to highlight IPython code or sessions.
The package is lightweight, has no known vulnerabilities, and fills a specific niche that standard Python lexers don't cover. Install it when you're building documentation, educational tools, or anything that displays IPython code and wants proper syntax coloring for magics and shell commands.
Install
ipython-pygments-lexers on PyPI
Before you install
Low friction install with a single runtime dependency on pygments. Maintenance status is aging—last commit was 2025-12-15, but the package is recent (first released 2025-01-15) and the repository remains active and not archived.
Requires pygments to be installed; Python >=3.8
License in practice
Licensed under BSD (permissive), so you can use, modify, and distribute the package with minimal legal restrictions.
Quickstart
pip install ipython-pygments-lexers
from pygments.lexers import get_lexer_by_name
lexer = get_lexer_by_name('ipythonconsole')
Verify before relying
- Whether the lexers handle all current IPython syntax features and special forms reliably
- Performance characteristics when highlighting large IPython session transcripts
Package facts
| License | permissive license permissive |
| Python support | Supports the current Python release >=3.8 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 1 packagepygments |
| Maintenance | Aging 574 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 78,556,467 / month, #435 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Framework :: IPythonLicense :: OSI Approved :: BSD License |
Evidence: ipython_pygments_lexers-1.1.1-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “ipython syntax highlighting”
- ipython-pygments-lexersProvides Pygments syntax highlighters for IPython code, console…
- flask-shell-ipythonReplaces Flask's default shell command with an IPython-powered…
- ipdbipdb is an IPython-enabled debugger that replaces Python's standard…
Give your agent the search over MCP, or paste the wish link into any chat.
More Text Processing packages
A drop-in replacement for Python's standard `re` module that adds advanced regex features like nested sets, fuzzy matching, lookaround in conditionals, and full Unicode case-folding while maintaining backward compatibility.
pyparsing provides a library for building text parsers directly in Python code using composable grammar classes, handling quoted strings, whitespace variation, and embedded comments without regex or lex/yacc.
Install it if you need to parse text or define grammars programmatically.
fonttools manipulates font files in multiple formats (TrueType, OpenType, AFM, Type 1, Mac-specific) and includes TTX, a tool to convert fonts to and from XML text format.
Install it if you need to read, write, or manipulate fonts programmatically or via the TTX command-line tool.
Docutils converts plaintext documentation in reStructuredText format into multiple output formats including HTML, XML, and LaTeX using a modular processing system.
RapidFuzz provides fast fuzzy string matching using Levenshtein Distance and related metrics, implemented mostly in C++ with Python bindings for rapid similarity scoring and approximate string matching.
Install it if you need fuzzy string matching; it's a solid replacement for FuzzyWuzzy with better licensing and performance.
tinycss2 parses CSS strings into token and block objects, and generates CSS strings from those objects, following the CSS Syntax Level 3 specification without enforcing specific properties or values.
Install it if your project requires CSS tokenization or syntax manipulation.
See also ansible-pygments · flask-shell-ipython · jupyterlab-pygments · Pygments · fluent.pygments · bpython · pygmars · ptpython · accessible-pygments · pygments-styles