PHPackages                             elvanto/litemoji - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. elvanto/litemoji

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

elvanto/litemoji
================

A PHP library simplifying the conversion of unicode, HTML and shortcode emoji.

5.2.0(10mo ago)864.6M↓10.7%16[1 issues](https://github.com/elvanto/litemoji/issues)[2 PRs](https://github.com/elvanto/litemoji/pulls)5MITPHPPHP &gt;=7.4CI passing

Since Feb 13Pushed 2mo ago3 watchersCompare

[ Source](https://github.com/elvanto/litemoji)[ Packagist](https://packagist.org/packages/elvanto/litemoji)[ RSS](/packages/elvanto-litemoji/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (2)Versions (37)Used By (5)

LitEmoji 🔥
==========

[](#litemoji-)

A PHP library simplifying the conversion of unicode, HTML and shortcode emoji.

[![Run Tests](https://github.com/elvanto/litemoji/workflows/Run%20Tests/badge.svg)](https://github.com/elvanto/litemoji/workflows/Run%20Tests/badge.svg)

Installation
------------

[](#installation)

```
$ composer require elvanto/litemoji

```

Alternatively you can clone or download the library files.

Usage
-----

[](#usage)

```
use LitEmoji\LitEmoji;

echo LitEmoji::encodeShortcode('Baby you light my 🔥! 😃');
// 'Baby you light my :fire:! :smiley:'

echo LitEmoji::encodeHtml('Baby you light my :fire:! :smiley:');
// 'Baby you light my &#x1F525;! &#x1F603;'

echo LitEmoji::encodeUnicode('Baby you light my :fire:! :smiley:');
// 'Baby you light my 🔥! 😃'

echo LitEmoji::removeEmoji('Baby you light my 🔥! 😃!!!');
// 'Baby you light my ! !!!'
```

Configuration
=============

[](#configuration)

```
use LitEmoji\LitEmoji;

// Exclude specific shortcodes when converting from unicode and HTML entities
LitEmoji::config('excludeShortcodes', ['mobile', 'android']);

echo LitEmoji::encodeShortcode('📱');
// ':iphone:'

// Add aliases for custom shortcodes
LitEmoji::config('aliasShortcodes', ['yeah' => 'thumbsup']);
echo LitEmoji::encodeUnicode('Can do :yeah:!');
// 'Can do 👍!'
```

Encodings
=========

[](#encodings)

LitEmoji's various functions will do their best to detect the encoding of the provided text and should work on UTF-8 encoded strings without issue. In cases where the encoding cannot be detected, UTF-8 is assumed, however a second argument can be provided to any of the functions to hint the actual encoded of the provided string.

Contributing
------------

[](#contributing)

Pull requests are welcome. New code must be fully unit tested (the existing test suite can be run with PHPUnit).

License
-------

[](#license)

[MIT License](LICENSE)

###  Health Score

62

—

FairBetter than 99% of packages

Maintenance70

Regular maintenance activity

Popularity58

Moderate usage in the ecosystem

Community28

Small or concentrated contributor base

Maturity75

Established project with proven stability

 Bus Factor1

Top contributor holds 54% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~102 days

Recently: every ~209 days

Total

31

Last Release

308d ago

Major Versions

1.4.4 → 2.0.02019-07-15

2.0.4 → 3.0.02020-11-27

3.0.1 → 4.0.02020-11-27

4.3.0-alpha → 5.0.0-alpha2023-03-28

PHP version history (5 changes)1.0.0PHP &gt;=5.4

2.0.0PHP &gt;=5.6

3.0.0PHP &gt;=7.0

4.0.0PHP &gt;=7.3

5.0.0-alphaPHP &gt;=7.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/77a936b5c659456479744d404f68ba7bca9552f1d008aa2cf3b8a9175c9ddfb4?d=identicon)[bensinclair](/maintainers/bensinclair)

![](https://www.gravatar.com/avatar/7cf1c2feb7af5eafbcec1d7258f9909e785bb27bda7ca57e47a2794241bf960c?d=identicon)[joshmcrae](/maintainers/joshmcrae)

---

Top Contributors

[![bensinclair](https://avatars.githubusercontent.com/u/1043658?v=4)](https://github.com/bensinclair "bensinclair (34 commits)")[![joshmcrae](https://avatars.githubusercontent.com/u/12324115?v=4)](https://github.com/joshmcrae "joshmcrae (24 commits)")[![Inkognitoo](https://avatars.githubusercontent.com/u/4684898?v=4)](https://github.com/Inkognitoo "Inkognitoo (1 commits)")[![brandonkelly](https://avatars.githubusercontent.com/u/47792?v=4)](https://github.com/brandonkelly "brandonkelly (1 commits)")[![KarelWintersky](https://avatars.githubusercontent.com/u/2164874?v=4)](https://github.com/KarelWintersky "KarelWintersky (1 commits)")[![loranger](https://avatars.githubusercontent.com/u/6014?v=4)](https://github.com/loranger "loranger (1 commits)")[![Spirit55555](https://avatars.githubusercontent.com/u/2357565?v=4)](https://github.com/Spirit55555 "Spirit55555 (1 commits)")

---

Tags

emojiphpunicodeemojiphp-emoji

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/elvanto-litemoji/health.svg)

```
[![Health](https://phpackages.com/badges/elvanto-litemoji/health.svg)](https://phpackages.com/packages/elvanto-litemoji)
```

###  Alternatives

[rinvex/countries

Rinvex Countries is a simple and lightweight package for retrieving country details with flexibility. A whole bunch of data including name, demonym, capital, iso codes, dialling codes, geo data, currencies, flags, emoji, and other attributes for all 250 countries worldwide at your fingertips.

1.7k7.4M48](/packages/rinvex-countries)[iamcal/php-emoji

This is a PHP library for dealing with Emoji, allowing you to convert between various native formats and displaying them using HTML.

1.3k481.1k](/packages/iamcal-php-emoji)[spatie/emoji

Display emoji characters

4671.2M32](/packages/spatie-emoji)[joypixels/emoji-toolkit

JoyPixels is a complete set of emoji designed for the web. The emoji-toolkit includes libraries to easily convert unicode characters to shortnames (:smile:) and shortnames to JoyPixels emoji images. PNG formats provided for the emoji images.

465817.1k7](/packages/joypixels-emoji-toolkit)[christofferok/laravel-emojione

Laravel helper for EmojiOne

139115.8k](/packages/christofferok-laravel-emojione)[unicodeveloper/laravel-emoji

A Laravel 5 Package for Using &amp; Working With Emojis

21024.9k](/packages/unicodeveloper-laravel-emoji)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
