Skip to content
Shahid Malla

WHMCS Live Chat Integration: Options Compared and Hook Setup

Add live chat to WHMCS the upgrade-safe way — and turn conversations into sales and faster support.

· Published · Updated · 11 min read
On this page (9 sections)

WHMCS live chat comes from five routes: the official Live Chat addon, a chat vendor's WHMCS module such as LiveChat or Crisp, any widget like tawk.to loaded from a hook, an AI chat module, or a custom build. Choose on whether agents see the signed-in client, whether chats land as WHMCS tickets, and whether you run WHMCS Cloud. On self-hosted WHMCS, load widgets from a hook.

What are the ways to add live chat to WHMCS?

WHMCS sells its own Live Chat addon. LiveChat and Crisp each publish a WHMCS module for their widget. Any other widget, tawk.to included, goes in with one hook file. AI chat modules answer from WHMCS data; one of them is MagizAI Live Chat for WHMCS, which I built. Disclosure: I am the founder and CEO of MagizAI, so weigh my view of it accordingly. Or you build your own. Vendor facts come from their own pages, read on 17 October 2026.

OptionWhere it runsKnows the signed-in client?Chats become WHMCS tickets?AI answers from WHMCS data?
WHMCS Live Chat addonSelf-hosted, inside your WHMCS (/modules/livehelp)Yes, with the client's products and billing in the chatYes, when the chat endsIts documentation does not mention AI
LiveChat moduleHosted by Text, LiveChat's maker; addon on your WHMCSIts WHMCS pages do not mention itYes, as closed tickets, if the pre-chat survey asks for an emailIts WHMCS pages do not mention it
Crisp pluginHosted by Crisp; addon on your WHMCSNot mentioned; the third-party WHMCS PRO plugin verifies signed-in clientsNot mentioned; WHMCS PRO lets an agent open oneNot mentioned
tawk.to or another widget via a hookHosted by the vendor; one hook file on your WHMCSOnly what your hook passes, signed on the serverThrough mail import or your own webhook endpointNot without your own code
MagizAI Live Chat for WHMCSHosted AI chat; free addon on your WHMCSYes, via a short-lived token the module signs; reads only that client's recordsOpens a ticket or hands the chat to staff, depending on setupYes: synced knowledgebase, announcements, plans and prices, plus the client's own services and invoices
Custom buildWhere you host itYes, as you design itYes, through the APIOnly if you build it

Which WHMCS live chat option works on WHMCS Cloud, and what does it cost?

On WHMCS Cloud, only a pasted snippet has a documented home. WHMCS says Cloud plans include specific lists of available addon modules; I found no Cloud documentation for uploading hook files or third-party addons, so ask WHMCS first.

OptionWHMCS CloudCost model (17 Oct 2026)Upkeep
WHMCS Live Chat addonNot supported, per WHMCSMonthly license: $6.95 one domain with branding, $9.95 without, $12.95 multi-domainYou host and update it
LiveChatIts pages do not say; setup uploads an addon, and ticket sync edits configuration.phpPer user per month, from $19 billed yearly (Text plans); no free plan listedVendor runs the service; ticket sync uses a WHMCS admin login
CrispIts pages do not say; setup uploads an addonFree plan with 2 seats; paid plans from $45 a month per workspaceVendor runs the service; keep the plugin current
tawk.to via a hookSnippet in footer.tpl via the Theme Editor; signed identity may not be possibleChat free; paid add-ons such as branding removal ($29 a month) and AI Assist (from $29 a month)One hook file to retest after WHMCS updates
MagizAIIts pages do not mention Cloud; setup uploads an addonModule free; plans $10 a month (your own AI key) to $99 a month; no free tierVendor runs the AI; you update the module and pick which actions are on
Custom buildPlan for self-hostedDevelopment time, plus any AI usageYours, at every WHMCS major update
  • WHMCS Live Chat addon. WHMCS launched it in 2010 with Stardevelop Live Help; the Marketplace listing now credits Chatstack. The WHMCS 9.0 documentation still covers it: upload upload_me into the WHMCS root and run /modules/livehelp/install. The listing, last updated 16 February 2023, names WHMCS up to 8.13 and PHP up to 8.1, while current WHMCS requires PHP 8.2 or 8.3. Ask about your version before buying.
  • LiveChat. Its WHMCS guide installs an addon with your license number; ticket sync asks for a WHMCS admin username and password and an $api_access_key line in configuration.php. The pricing page calls Text the next product from the LiveChat team.
  • Crisp. The install guide uploads a crisp folder to modules/addons/ with a license key. Lennmedia's third-party WHMCS PRO plugin syncs clients and shows agents their products, invoices and tickets; its listing states no price.
  • tawk.to. The pricing page lists the chat as free. The hook below loads it; identity and tickets are yours to wire.
  • MagizAI. The module is free on the WHMCS Marketplace, listed as compatible with WHMCS 9.0; the chat needs a paid plan. Account actions such as nameserver changes start switched off, and the client confirms each one. Limits: no free tier, your public content goes to a third-party service, and answers are only as good as your knowledgebase. Details on my MagizAI page.
  • Custom build. Worth it when agents need WHMCS data the products above do not show. My WHMCS AI chatbot page compares a module, an n8n workflow and custom code.

If price decides it, my guide to free live chat for WHMCS covers what each free tier includes. For staffing and when a ticket beats a chat, read live chat for web hosting companies.

How do I add a live chat widget to WHMCS without editing a template?

Put one PHP file in /includes/hooks/ that returns the vendor's embed code from the ClientAreaFooterOutput hook. The hook documentation says hooks live there and a leading underscore excludes a file, so renaming it _livechat.php is your off switch. This example loads tawk.to; other vendors' snippets work the same way.

<?php
// includes/hooks/livechat.php
if (!defined('WHMCS')) {
    die('This file cannot be accessed directly');
}

function tawkLoader(): string
{
    $src = 'https://embed.tawk.to/PROPERTY_ID/WIDGET_ID'; // yours
    return <<<HTML
<script>
var Tawk_API = Tawk_API || {}, Tawk_LoadStart = new Date();
(function () {
  var s1 = document.createElement('script'), s0 = document.getElementsByTagName('script')[0];
  s1.async = true; s1.src = '{$src}'; s1.charset = 'UTF-8';
  s1.setAttribute('crossorigin', '*');
  s0.parentNode.insertBefore(s1, s0);
})();
</script>
HTML;
}

add_hook('ClientAreaFooterOutput', 1, function ($vars) {
    return tawkLoader();
});

The output hook reference places three client area hooks: ClientAreaHeadOutput inside the head, ClientAreaHeaderOutput at the top of the body and ClientAreaFooterOutput before the closing body tag. A widget is not needed for first paint, so use the footer. Pasting into footer.tpl instead breaks three ways: an update overwrites a stock theme file, a copied footer in a child theme stops inheriting the parent's fixes (see my theme structure guide), and a theme switch drops the widget.

If nothing appears, run php -l on the file, enable Log Errors in the Other tab of Configuration > System Settings > General Settings, and read the Activity Log under Configuration > System Logs, per the logs documentation. My WHMCS hooks guide covers the rest. On WHMCS Cloud, the Theme Editor edits footer.tpl in a theme you create.

How do I pass the signed-in client into the chat?

Read the session with WHMCS\Authentication\CurrentUser, added in WHMCS 8.0, and set the visitor before the widget loads. Its user() and client() return an object or null, and isMasqueradingAdmin() is true after an admin clicks Login as Owner. The CurrentUser documentation warns that these states are not mutually exclusive, so test for the one you mean. Replace the add_hook call above with this:

add_hook('ClientAreaFooterOutput', 1, function ($vars) {
    $currentUser = new \WHMCS\Authentication\CurrentUser();
    if ($currentUser->isMasqueradingAdmin()) {
        return ''; // no widget under Login as Owner
    }
    $user   = $currentUser->user();
    $client = $currentUser->client();
    if (!$user || !$client) {
        return tawkLoader(); // guests get the anonymous widget
    }

    // HEX flags keep the JSON safe inside a script tag, O'Brien included
    $visitor = json_encode([
        'name'  => $user->fullName,
        'email' => $user->email,
        'hash'  => hash_hmac('sha256', $user->email, chatApiKey()),
    ], JSON_HEX_TAG | JSON_HEX_AMP | JSON_HEX_APOS | JSON_HEX_QUOT);
    $clientId = (int) $client->id;

    $identity = <<<HTML
<script>
var Tawk_API = Tawk_API || {};
Tawk_API.visitor = {$visitor};
Tawk_API.onLoad = function () {
  Tawk_API.setAttributes({ clientid: '{$clientId}' }, function (error) {});
};
</script>
HTML;
    return $identity . tawkLoader();
});

Never wrap values in quotes yourself: a client called O'Brien breaks the script, and a crafted name can inject code. fullName is the property the documentation shows; dump the objects on staging before relying on others.

How do I stop a visitor faking another client's identity?

Sign the identity on the server, because anything the page sends can be edited in the browser console. tawk.to calls this secure mode, and its JavaScript API documentation defines the hash as a server-side HMAC using SHA256, the user's email and your site's API key from Admin > Property Settings. That is the hash_hmac line above; chatApiKey() should read the key from a file outside the web root. Other vendors use the same pattern under their own names.

The same page caps custom attributes at 50 beyond name, email and hash, allows only letters, numbers and dashes in keys and rejects values over 255 characters, so send a client ID, not the account. Until the hash is in place, the name in the widget is a hint, not proof for discussing billing.

How do you set up the LiveChat WHMCS integration?

LiveChat (livechat.com) publishes its own WHMCS integration in two parts, set out in its WHMCS integration guide (last updated 20 September 2022; read 22 October 2026):

  1. Chat widget. Put LiveChat's addon in /modules/addons, activate it on the Addon Modules page and enter your LiveChat license number in its settings. The guide still shows the older Setup menu; recent WHMCS documentation places that page under Configuration, then System Settings, then Addon Modules.
  2. Chats as tickets. Install the WHMCS app inside LiveChat, enter your WHMCS address and an admin login, give it the support department ID and add an API access key to configuration.php. Finished chats then arrive as closed tickets, but only when the pre-chat survey asks for an email address.

Two cautions. WHMCS documents that the access key allows IP restrictions to be bypassed, so keep it long and private. And give LiveChat its own WHMCS admin user instead of your own login, so you can switch it off without locking yourself out.

How do I turn a finished chat into a WHMCS ticket?

Use the simplest route that leaves a record in WHMCS, because a chat your help desk cannot see did not happen. The official addon and the LiveChat module file transcripts as tickets themselves. A vendor that emails transcripts can send them to a department that imports mail. Otherwise, receive the vendor's webhook and call the API. tawk.to's webhooks send a chat:transcript_created event with the messages and the visitor's name and email, signed with HMAC-SHA1 in an X-Tawk-Signature header:

<?php
// chat-webhook.php in the WHMCS root; webhookSecret() reads a file outside it
require __DIR__ . '/init.php';

$body = file_get_contents('php://input');
$sent = $_SERVER['HTTP_X_TAWK_SIGNATURE'] ?? '';
if (!hash_equals(hash_hmac('sha1', $body, webhookSecret()), $sent)) {
    http_response_code(401);
    exit;
}
$event = json_decode($body, true);
if (($event['event'] ?? '') !== 'chat:transcript_created') {
    exit;
}

$visitor = $event['chat']['visitor'];
$lines = [];
foreach ($event['chat']['messages'] as $m) {
    $who = $m['sender']['t'] === 'v' ? 'Visitor' : ($m['sender']['n'] ?? 'Agent');
    $lines[] = "**{$who}:** " . ($m['msg'] ?? '');
}
$ticket = ['deptid' => 1, 'subject' => 'Chat transcript', 'priority' => 'Low',
           'message' => implode("\n\n", $lines), 'markdown' => true];

$found = localAPI('GetClientsDetails', ['email' => $visitor['email'] ?? '']);
if ($found['result'] === 'success') {
    $ticket['clientid'] = $found['client']['id'];
} else {
    $ticket['name']  = $visitor['name'];
    $ticket['email'] = $visitor['email'] ?? '';
}
$result = localAPI('OpenTicket', $ticket);
if ($result['result'] !== 'success') {
    logActivity('Chat ticket failed: ' . $result['message']);
}

The OpenTicket reference lists these parameters, says a ticket without clientid needs a name and email, and documents errors such as Department ID not found after departments are renumbered. GetClientsDetails searches the client's email, so a sub-user's chat becomes a guest ticket. My WHMCS API guide covers authentication.

How do I test the chat before it goes live?

  1. As a guest, the widget loads and starts an anonymous chat.
  2. Signed in as a test client, the agent sees that client's name and email.
  3. With an apostrophe in the test client's name, the page still runs.
  4. Under Login as Owner, no widget and no identity appear.
  5. Editing the identity in the browser console fails once secure mode is on.
  6. A finished test chat appears as a ticket under the right client.
  7. On a phone, the bubble does not cover the order or pay button; if it does, move it in the vendor's settings or css/custom.css.
  8. With CDN script minifying or deferring, a Content-Security-Policy header or an ad blocker, the widget starts or checkout works without it; exclude or allow the vendor's hosts.

Repeat steps 1, 2 and 6 on staging after every WHMCS update.

When is live chat the wrong answer?

When nobody is going to answer it. An unanswered bubble costs more trust than no bubble, so publish real hours and route offline messages into tickets. Two further limits. Client names and emails go to a third party, which belongs in your privacy policy and, where required, behind consent; see my WHMCS GDPR guide. And no snippet puts open tickets, services and unpaid invoices beside the chat for your agents; that takes the official addon, a sync plugin such as WHMCS PRO, or a screen built for your team. For that screen, see custom WHMCS module development: a free call of about 30 minutes, then a written quote within one business day.

Last reviewed 17 October 2026. Disclosure: I am the founder and CEO of MagizAI, so weigh my view of it accordingly. I also sell custom WHMCS development, am CTO at ElySpace, a hosting company, and founded WHMCSPilot. I am not affiliated with WHMCS, Text (LiveChat), Crisp or tawk.to, and no link here is an affiliate link. Vendor facts come from each vendor's own pages on that date.

Share this article

Shahid Malla

Written by

Shahid Malla

Freelance WHMCS developer and web designer with 13+ years of client work. CTO at ElySpace, freelance developer for Marmaids LLC, and founder of WHMCSPilot and MagizAI.

Got a project like this?

Tell me what you need and I will send a written quote within one business day.