PHPackages                             coliff/freshdesk-messaging-facade - 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. [API Development](/categories/api)
4. /
5. coliff/freshdesk-messaging-facade

ActiveLibrary[API Development](/categories/api)

coliff/freshdesk-messaging-facade
=================================

A faster Freshdesk Messaging (formerly Freshchat) embed

v1.3.2(11mo ago)1575[1 PRs](https://github.com/coliff/freshdesk-messaging-facade/pulls)MITJavaScriptCI passing

Since Oct 25Pushed 1mo ago2 watchersCompare

[ Source](https://github.com/coliff/freshdesk-messaging-facade)[ Packagist](https://packagist.org/packages/coliff/freshdesk-messaging-facade)[ Fund](https://paypal.me/coliff)[ RSS](/packages/coliff-freshdesk-messaging-facade/feed)WikiDiscussions main Synced today

READMEChangelog (6)DependenciesVersions (19)Used By (0)

[![LICENSE](https://camo.githubusercontent.com/891419a00e04aa0e311068fa8a04eec92cab4f7026c76278279bf2a1da50e578/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d6c69676874677265792e737667)](https://raw.githubusercontent.com/coliff/freshdesk-messaging-facade/main/LICENSE)[![GitHub Super-Linter](https://github.com/coliff/freshdesk-messaging-facade/workflows/Lint%20Code%20Base/badge.svg)](https://github.com/marketplace/actions/super-linter)[![code style: prettier](https://camo.githubusercontent.com/fa1096c501361805c36b519890a25f61cd45dde376718bb2f5af65a656f4c0fa/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f64655f7374796c652d70726574746965722d6666363962342e7376673f7374796c653d666c61742d737175617265)](https://github.com/prettier/prettier)[![npm Version](https://camo.githubusercontent.com/e41a0443540e07ac77519dfe12b08f37bcf6c824f8c5bab9fa77207e6de1bac7/68747470733a2f2f696d672e736869656c64732e696f2f6e706d2f762f66726573686465736b2d6d6573736167696e672d666163616465)](https://www.npmjs.com/package/freshdesk-messaging-facade)[![npm Downloads](https://camo.githubusercontent.com/0f8b92c2181afc15cb421ac749d5802afec931cd33d1befb6c526767a6600b91/68747470733a2f2f696d672e736869656c64732e696f2f6e706d2f64742f66726573686465736b2d6d6573736167696e672d6661636164652e737667)](https://www.npmjs.com/package/freshdesk-messaging-facade)

Freshdesk Messaging (Freshchat) Facade
======================================

[](#freshdesk-messaging-freshchat-facade)

The [Freshchat](https://developers.freshchat.com/web-sdk/) widget loads more than 1.1 MB (gzipped) of JavaScript on page-load.

This facade (less than 1 KB gzipped) prevents Freshchat's JavaScript from loading until the chat widget is hovered over saving your users a lot of bandwidth and substantially improving page-load times.

Comparison
----------

[](#comparison)

Freshchat JSFreshchat FacadeNumber of assets282Page Complete6.3 s1.1 sNetwork Transfer size1097 KB1 KBHow it works
------------

[](#how-it-works)

A div with an inline SVG of the Freshchat icon is displayed in the bottom corner - appearing just like the real thing. When a user hovers within 200 pixels of it loads the Freshdesk Messaging script. A simple animated icon is displayed as the script loads.

Quick start
-----------

[](#quick-start)

Several quick start options are available:

- [Download the latest release](https://github.com/coliff/freshdesk-messaging-facade)
- Clone the repo `git clone https://github.com/coliff/freshdesk-messaging-facade.git`
- Install with [npm](https://www.npmjs.com/package/freshdesk-messaging-facade) `npm install freshdesk-messaging-facade`
- Install with [yarn](https://yarnpkg.com/en/package/freshdesk-messaging-facade) `yarn add freshdesk-messaging-facade`
- Install with [Composer](https://packagist.org/packages/coliff/freshdesk-messaging-facade) `composer require coliff/freshdesk-messaging-facade`

Usage
-----

[](#usage)

1. Load the CSS and JS in your head:

    ```

    ```
2. Load the web component within your page:

    ```

    ```

    Add your 36-digit Freshchat token to the `data-token` and your site's id to `data-siteid`.

    You can optionally add a `data-host` attribute to set the host of the widget. The default is `https://wchat.freshchat.com`.

Demo
----

[](#demo)

FAQs
----

[](#faqs)

- **Q. How can I customize the chat widget's color?**

    A. You can modify the `background-color` value of `#freshdesk-messaging-icon`.
- **Q. Can I load this from a CDN?**

    A. Yep, it's available on [JSDelivr](https://www.jsdelivr.com/package/npm/freshdesk-messaging-facade).
- **Q. Does it work in IE 11?**

    A. No, but you can easily load the standard Freshdesk Messaging widget and add the `nomodule` attribute to it as a fallback for legacy browsers. [View Gist](https://gist.github.com/coliff/fe18a182c8224d8d92ae1c31a31d756f)

Known Issues
------------

[](#known-issues)

- Some content blockers on iOS may block the Freshdesk Messaging widget leading to the facade being non-functioning.
- The Freshdesk Messaging widget and assets are large so it can take a couple of seconds for them to load.

Credits and thanks
------------------

[](#credits-and-thanks)

- This project is inspired by the [Lite YouTube Embed](https://github.com/paulirish/lite-youtube-embed) project by Paul Irish.
- Thanks to Yoksel for the useful [SVG to CSS converter](https://yoksel.github.io/url-encoder/)

###  Health Score

43

—

FairBetter than 91% of packages

Maintenance75

Regular maintenance activity

Popularity14

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 68% 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 ~331 days

Total

5

Last Release

335d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/a6068e9ba0ce8defec6b107f1cc3b99c2fd91f75298b48f71cc3dbfdc20870a8?d=identicon)[coliff](/maintainers/coliff)

---

Top Contributors

[![coliff](https://avatars.githubusercontent.com/u/1212885?v=4)](https://github.com/coliff "coliff (204 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (93 commits)")[![Codex](https://avatars.githubusercontent.com/in/2248422?v=4)](https://github.com/Codex "Codex (2 commits)")[![step-security-bot](https://avatars.githubusercontent.com/u/89328645?v=4)](https://github.com/step-security-bot "step-security-bot (1 commits)")

---

Tags

facadefreshchatfreshdesk

### Embed Badge

![Health badge](/badges/coliff-freshdesk-messaging-facade/health.svg)

```
[![Health](https://phpackages.com/badges/coliff-freshdesk-messaging-facade/health.svg)](https://phpackages.com/packages/coliff-freshdesk-messaging-facade)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M271](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[microsoft/microsoft-graph

The Microsoft Graph SDK for PHP

65723.5M96](/packages/microsoft-microsoft-graph)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)

PHPackages © 2026

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