Skip to content
Back to open source

universal-emoji-parser

Parse unicode and emoji shortcodes into consistent HTML images — battle-tested since Dailybot 1.0.

universal-emoji-parser is the tiny library Dailybot has used since day one to keep emoji rendering identical across every surface — Slack, Microsoft Teams, Discord, Google Chat, and the browser. It parses any mix of unicode emoji and shortcodes (`:rocket:`, `:tada:`, `:heart:`) into consistent HTML `<img>` tags backed by Twemoji. That's how a report a human writes on Slack looks the same when a bot renders it in-app, in an email, or in a customer's browser.

License: MITPrimary language: TypeScript

1,898

curated emoji entries

2-way

unicode ↔ shortcode conversion

Twemoji

consistent image rendering

MIT

licensed, end to end

Why it exists

The bits that make it worth adopting.

1,898 curated emoji entries

A hand-maintained catalog of the emoji that actually get used in team chat — no bloat, no obscure Unicode 15 candidates. Every entry has a name, shortcode, unicode, and Twemoji reference.

Unicode ↔ shortcode both ways

Parse a message containing `🚀` and render `:rocket:`, or parse `:rocket:` and render `🚀`. Either direction, same one function call, same output.

Custom CDN + HTML tag support

Point the parser at your own Twemoji CDN, use a custom HTML tag (`<span>`, `<i>`, etc.), or add a custom class. The library adapts to your rendering stack, not the other way around.

Battle-tested since Dailybot 1.0

The same emoji parser has run in every version of Dailybot since day one. Every kudo, every reaction, every report you've ever seen in Dailybot passes through this library.

Tiny, dependency-light

Small TypeScript bundle, no framework dependencies. Works in Node, the browser, and edge runtimes.

MIT + fully forkable

The whole library is MIT-licensed. Fork it, extend the catalog, adapt it to your CDN — the code and licence say yes.

Install

Get started in seconds.

Pick the channel that matches your stack. Every path lands you in the same working state.

npm i universal-emoji-parser

In practice

What teams actually do with it.

01

Consistent emoji rendering across surfaces

A user types `:rocket:` in Slack. Your integration echoes it to Microsoft Teams, Discord, and your customer's inbox. All four surfaces show the same Twemoji glyph, not four different vendor renderings.

02

Rich-text editors that speak both formats

Users paste `🚀` from their keyboard, type `:rocket:` from muscle memory, or copy from another app. The editor parses both and renders identically.

03

Chat history that survives platform migrations

Moving from Slack to Teams (or the other way)? The parser normalizes every historical message into a canonical HTML form, then re-renders it for the new platform's conventions.

At a glance

The short list.

1,898 curated emoji entries

Unicode ↔ shortcode both ways

Custom CDN and HTML tag options

Twemoji-backed image rendering

FAQ

The questions we hear the most.

Do I need Twemoji?

Twemoji is the default, but the library accepts any CDN URL. Point it at your own emoji set and it'll render those instead.

Does it support all Unicode emoji?

It supports the curated set of ~1,898 emoji that actually get used in team chat. That's a deliberate choice — obscure Unicode candidates get filtered out to keep the bundle small.

Can I extend the catalog with custom emoji?

Yes. Register a custom emoji with its own shortcode, unicode, or image URL. The parser treats it identically to the built-in catalog.

What it is

universal-emoji-parser is a small, focused TypeScript library that keeps emoji rendering consistent across every surface — chat, email, in-app UI. It’s the same library Dailybot has used since day one to make sure :rocket: looks like a rocket everywhere.

Why open source

Because “why does the emoji look different on Slack vs Teams?” is a solved problem, and the solution should be shareable. MIT-licensed, developed in the open, and used in production by Dailybot every day.

How it fits the ecosystem

Every Dailybot surface that renders user-generated content — reports, kudos, forms, chat replies — passes through this parser. Its stability is Dailybot’s stability. Making it open source means anyone building multi-surface chat UI can borrow the same guarantee.

Ready to try it?

Open source, MIT-licensed, and shipping in production at Dailybot every day. Fork it, wire it in, contribute back.