EmojiKit lets you work with emojis in a more structured way



EmojiKit has an Emoji struct that lets you work with emojis in a more structured way:

let emoji = Emoji("πŸ˜€")

You can use Emoji.all to get a list of all emojis from all categories, that are available to the currently exeucting runtime:

let emojis = Emoji.all          // πŸ˜€πŸ˜ƒπŸ˜„πŸ˜πŸ˜†πŸ₯ΉπŸ˜…πŸ˜‚πŸ€£πŸ₯²...

The Emoji type also serves as a namespace for most EmojiKit features, which means that most types are wrapped within this struct.

Unicode Information

The Emoji type has unicode-specific properties that are used for identity and naming:

Emoji("πŸ‘").unicodeIdentifier   // \\N{THUMBS UP SIGN}
Emoji("πŸ‘πŸΏ").unicodeIdentifier   // \\N{THUMBS UP SIGN}\\N{EMOJI MODIFIER FITZPATRICK TYPE-6}
Emoji("πŸš€").unicodeIdentifier   // \\N{ROCKET}
Emoji("πŸ‘").unicodeName         // Thumbs Up Sign
Emoji("πŸ‘πŸΏ").unicodeName         // Thumbs Up Sign
Emoji("πŸš€").unicodeName         // Rocket

These properties have manual overrides for emojis that lack proper information, such as flags.

The Emoji type supports searching for emojis that matches certain search queries:

Emoji("πŸ‘").matches("thumb")    // true
Emoji("πŸ‘πŸΏ").matches("thumb")    // true
Emoji("πŸš€").matches("thumb")    // true

[Emoji("πŸ‘"), Emoji("πŸ‘πŸΏ") Emoji("πŸš€")]
    .matching("thumb")          // πŸ‘, πŸ‘πŸΏ

This can be used to quickly filter emojis in code or letting users search for specific emojis.


EmojiKit has String and Character extensions that can be used to detect and handle emojis:

"Hello!".containsEmoji          // false
"Hello! πŸ‘‹".containsEmoji       // true
"Hello! πŸ‘‹".containsOnlyEmojis  // false
"πŸ‘‹".containsOnlyEmojis         // true
"Hello! πŸ‘‹πŸ˜€".emojis            // ["πŸ‘‹", "πŸ˜€"]
"Hello! πŸ‘‹πŸ˜€".emojiString       // "πŸ‘‹πŸ˜€"
"🫸🫷".isSingleEmoji            // false
"πŸ‘".isSingleEmoji              // true

These extensions are used to power many library features, but can be used stand-alone as well.

Read More


The license tiers are aimed at indies and small businesses. Reach out for a custom plan if you’re an enterprise, have $10M+ in annual revenue, or if your product exceeds $1M in annual proceeds.

Our SDKs