demoji
Accurately remove and replace emojis in text strings
Decision gist · record as of 2026-08-14
Yes. demoji is lightweight, dependency-free, actively maintained, and solves a real problem with high accuracy. It handles edge cases (multi-character sequences, skin tones, flags) correctly and works offline. Use it whenever you need to find, extract, or normalize emojis in text.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later (supports 3.10–3.14).
- Low friction: pure Python wheel with no runtime dependencies.
- Actively maintained, last commit 2026-07-12, with Unicode emoji data bundled at install time so no network calls are needed at runtime.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 is permissive; you can use demoji freely in commercial and private projects with minimal restrictions.
last release 2026-04-19 (117 days) · last repo commit 2026-07-12 · 163 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 338,151 downloads/mo, #7,436 on PyPI
Alternatives
Verify before relying
pip install demoji
import demoji
text = "Great game! 🔥 🎉"
print(demoji.findall(text))
# {'🔥': 'fire', '🎉': 'party popper'}
print(demoji.replace_with_desc(text))
# Great game! :fire: :party popper:- Whether the bundled Unicode emoji data (version 16.0) can be updated independently of package releases.
- Performance characteristics when processing very large text blobs or documents with thousands of emojis.
What it is and what it does
demoji is a text-processing library that accurately identifies and manipulates emojis in strings. It bundles Unicode Consortium emoji data at install time, so it works offline and requires no network access at runtime. The package handles complex emoji sequences—like skin-tone modifiers, zero-width joiners, and flag combinations—by sorting emoji codes by length and using a greedy regex approach to match longer sequences before shorter ones.
You can use it to find all emojis in a string and get their descriptions, extract emojis as a list, replace them with plain text, or convert them to colon-delimited codes (like `:fire:` for 🔥). It also provides a command-line interface for batch processing files or stdin. The library is typed, actively maintained, and supports modern Python versions.
Use it for
- Clean user-generated content (tweets, comments, chat) by replacing emojis with text descriptions for downstream NLP or storage.
- Extract and catalog emojis from social media feeds or message logs to understand sentiment or trending symbols.
- Convert emoji-heavy text to plain ASCII for systems that don't render emoji or for accessibility.
- Validate or audit text fields in forms or databases to detect and flag emoji usage.
- Build emoji-aware text search or indexing by mapping emojis to their semantic descriptions.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
demoji is lightweight, dependency-free, actively maintained, and solves a real problem with high accuracy. It handles edge cases (multi-character sequences, skin tones, flags) correctly and works offline. Use it whenever you need to find, extract, or normalize emojis in text.
Install
demoji on PyPI
Before you install
Low friction: pure Python wheel with no runtime dependencies. Actively maintained, last commit 2026-07-12, with Unicode emoji data bundled at install time so no network calls are needed at runtime.
Requires Python 3.10 or later (supports 3.10–3.14).
License in practice
Apache-2.0 is permissive; you can use demoji freely in commercial and private projects with minimal restrictions.
Quickstart
pip install demoji
import demoji
text = "Great game! 🔥 🎉"
print(demoji.findall(text))
# {'🔥': 'fire', '🎉': 'party popper'}
print(demoji.replace_with_desc(text))
# Great game! :fire: :party popper:
Verify before relying
- Whether the bundled Unicode emoji data (version 16.0) can be updated independently of package releases.
- Performance characteristics when processing very large text blobs or documents with thousands of emojis.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release <3.15,>=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 117 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 338,151 / month, #7,436 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: Implementation :: CPythonTopic :: Text ProcessingTopic :: Text Processing :: LinguisticTopic :: UtilitiesTyping :: Typed |
Evidence: demoji-2.0.0-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 › “emoji detection and removal”
- demojidemoji finds and removes emojis from text, mapping each emoji to its…
- emotExtracts emojis and emoticons from text, returning their positions,…
- emojiConverts between emoji characters and their text code names (e.g.,…
Give your agent the search over MCP, or paste the wish link into any chat.
More Utilities packages
Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.
Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.
Detects and normalizes text encoding from unknown or ambiguous sources, supporting all IANA character sets that Python's core library provides codecs for, with the ability to register custom codecs.
Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.
Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.
Install it if you're building an extensible application or framework.
Pygments is a syntax highlighter that colorizes source code and text in over 500 languages and formats, outputting to HTML, LaTeX, RTF, SVG, images, or ANSI terminal sequences.
Install it if you need to display or transform source code.
Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.
See also ecoji · emot · emoji · anyascii · strip-ansi · grapheme · graphemeu · pytest-emoji · emoji-country-flag