Shahid Malla

WHMCS WhatsApp Integration: Complete Guide

Shahid Malla Shahid MallaJanuary 12, 202611 min read
WHMCS WhatsApp Integration: Complete Guide

WhatsApp has 2+ billion users and 98% message open rates. Integrating it with WHMCS dramatically improves payment recovery and customer engagement compared to email alone.

Why WhatsApp for WHMCS?

  • Higher open rates: 98% vs 20% for email
  • Faster response: Messages read within minutes
  • Better payment recovery: 40-60% improvement in overdue collections
  • Modern experience: Customers prefer messaging apps

Integration Methods

1. WhatsApp Business API

Official API for automated messaging. Requires business verification and approved message templates. Best for high-volume, compliant messaging.

2. Third-Party Providers

Services like Twilio, MessageBird, or Wati provide easier API access with pre-approved templates and better support.

3. WHMCS Hooks + API

Custom hooks trigger WhatsApp messages on WHMCS events like new orders, invoice creation, and payment reminders.

Common Use Cases

  • New order confirmation: Instant WhatsApp with order details
  • Invoice notifications: Send invoice links via WhatsApp
  • Payment reminders: 3-day, 1-day, and overdue reminders
  • Service credentials: Send login details securely
  • Support updates: Ticket status notifications

Sample Hook Implementation

<?php
add_hook('InvoiceCreated', 1, function($vars) {
    $invoiceId = $vars['invoiceid'];
    $invoice = localAPI('GetInvoice', ['invoiceid' => $invoiceId]);
    $client = localAPI('GetClientsDetails', ['clientid' => $invoice['userid']]);
    
    $phone = $client['phonenumber'];
    $message = "Hi " . $client['firstname'] . ", Invoice #$invoiceId for $" . $invoice['total'] . " is ready. Pay here: " . $invoice['paymentlink'];
    
    sendWhatsAppMessage($phone, $message);
});

Best Practices

  • Get explicit consent before sending WhatsApp messages
  • Use approved message templates for Business API
  • Don't spam - limit to important notifications
  • Provide opt-out option
  • Test thoroughly before production

Conclusion

WhatsApp integration transforms WHMCS communication. Faster payments, better engagement, and happier customers. The investment in integration pays for itself in improved collection rates.

Share this article:
Shahid Malla

About Shahid Malla

Expert

Full Stack Developer with 10+ years of experience in WHMCS development, WordPress, and server management. Trusted by 600+ clients worldwide for hosting automation and custom solutions.