Skip to content

Deploying Live Helper Chat

Introduction

Live Helper Chat is a comprehensive open-source live support solution that goes far beyond basic chat functionality. With built-in support for chatbots, voice calls, video calls, and screen sharing, Live Helper Chat provides enterprise-grade customer support capabilities in a self-hosted package. The platform is designed to handle high-traffic websites while maintaining low resource consumption.

Built with PHP and modern web technologies, Live Helper Chat has been actively developed since 2010 and powers customer support for thousands of websites worldwide. The application includes advanced features like automated responses, proactive chat invitations, department routing, and extensive integration capabilities through webhooks and APIs.

Key highlights of Live Helper Chat:

  • Multi-Channel Support: Chat, voice, video, and screen sharing in one platform
  • Chatbot Integration: Built-in bot framework with AI capabilities
  • Proactive Invitations: Automatically engage visitors based on behavior
  • Department Routing: Route chats to the right team automatically
  • Canned Responses: Speed up support with pre-written responses
  • Co-Browsing: View and navigate visitor screens in real-time
  • Visitor Tracking: Monitor visitor behavior and page views
  • Multi-Operator: Support multiple agents with concurrent chats
  • Mobile Apps: Native iOS and Android apps for operators
  • Workflow Automation: Integrate with n8n and other automation tools
  • Full Customization: Extensive theming and branding options
  • Open Source: GPL licensed with active community development

This guide walks through deploying Live Helper Chat on Klutch.sh using Docker, configuring the chat system, and optimizing for production use.

Why Deploy Live Helper Chat on Klutch.sh

Deploying Live Helper Chat on Klutch.sh provides several advantages:

Complete Feature Set: Docker deployment includes all components for chat, Node.js for real-time features, cobrowsing, and background job processing.

Persistent Storage: Attach persistent volumes for your database, uploaded files, and chat history. Conversations and configurations survive restarts.

HTTPS by Default: Klutch.sh provides automatic SSL certificates, essential for secure customer communications and building trust.

GitHub Integration: Connect your configuration repository directly from GitHub. Push updates to trigger automatic redeployments.

Scalable Resources: Allocate CPU and memory based on expected chat volume. Scale up during busy periods.

Environment Variable Security: Store database credentials and API keys securely through Klutch.sh’s environment variable system.

Custom Domains: Use your own domain for a branded support experience that matches your website.

Always-On Availability: Your support chat remains available 24/7 without managing infrastructure.

Prerequisites

Before deploying Live Helper Chat on Klutch.sh, ensure you have:

  • A Klutch.sh account
  • A GitHub account with a repository for your configuration
  • Basic familiarity with Docker and containerization concepts
  • A website where you want to add live chat
  • (Optional) A custom domain for your chat system
  • (Optional) SMTP credentials for email notifications

Understanding Live Helper Chat Architecture

Live Helper Chat uses a multi-component architecture for full functionality:

PHP Application: The core application handles chat logic, user management, and the admin interface. Built on a custom MVC framework optimized for real-time communication.

Node.js Server: Provides WebSocket connections for real-time messaging, eliminating the need for polling and reducing latency.

Database: MySQL/MariaDB stores chat history, user data, configurations, and analytics.

Background Workers: PHP-resque handles background tasks like email notifications, bot responses, and data processing.

Cobrowsing Server: Optional Node.js server for screen sharing and co-browsing functionality.

Preparing Your Repository

To deploy Live Helper Chat on Klutch.sh, create a GitHub repository containing your Docker configuration.

Repository Structure

livehelperchat-deploy/
├── Dockerfile
├── docker-compose.yml
└── .dockerignore

Creating the Dockerfile

Create a Dockerfile in the root of your repository:

FROM livehelperchat/livehelperchat:latest
# Set environment variables
ENV LHC_SECRET_HASH=${LHC_SECRET_HASH}
ENV LHC_WEBHOOKS_ENABLED=1
# Create necessary directories
RUN mkdir -p /var/www/html/var/storage
# Expose the web interface port
EXPOSE 80
# The base image includes the default entrypoint

Creating the Docker Compose Configuration

Create a docker-compose.yml for reference:

version: '3.8'
services:
lhc:
image: livehelperchat/livehelperchat:latest
container_name: livehelperchat
restart: unless-stopped
ports:
- "8080:80"
environment:
- LHC_SECRET_HASH=${LHC_SECRET_HASH}
- LHC_DB_HOST=${LHC_DB_HOST}
- LHC_DB_USER=${LHC_DB_USER}
- LHC_DB_PASS=${LHC_DB_PASS}
- LHC_DB_NAME=${LHC_DB_NAME}
- LHC_DB_PORT=3306
volumes:
- lhc_storage:/var/www/html/var/storage
- lhc_cache:/var/www/html/cache
volumes:
lhc_storage:
lhc_cache:

Creating the .dockerignore File

Create a .dockerignore file:

.git
.github
*.md
LICENSE
.gitignore
*.log
.DS_Store
.env
.env.local

Environment Variables Reference

Live Helper Chat requires several environment variables:

VariableRequiredDescription
LHC_SECRET_HASHYesSecret key for session security
LHC_DB_HOSTYesDatabase hostname
LHC_DB_USERYesDatabase username
LHC_DB_PASSYesDatabase password
LHC_DB_NAMEYesDatabase name
LHC_DB_PORTNoDatabase port (default: 3306)
LHC_WEBHOOKS_ENABLEDNoEnable webhook integrations

Deploying Live Helper Chat on Klutch.sh

Once your repository is prepared, follow these steps to deploy:

    Generate Security Hash

    Generate a secure secret hash:

    Terminal window
    openssl rand -hex 32

    Save this securely for environment variables configuration.

    Push Your Repository to GitHub

    Initialize your repository and push to GitHub:

    Terminal window
    git init
    git add Dockerfile docker-compose.yml .dockerignore
    git commit -m "Initial Live Helper Chat deployment configuration"
    git remote add origin https://github.com/yourusername/livehelperchat-deploy.git
    git push -u origin main

    Set Up Database

    Before deploying, ensure you have a MySQL/MariaDB database ready. You can use Klutch.sh’s database services or an external provider.

    Create a New Project on Klutch.sh

    Navigate to the Klutch.sh dashboard and create a new project. Give it a descriptive name like “livehelperchat” or “support-chat”.

    Create a New App

    Within your project, create a new app. Connect your GitHub account if you haven’t already, then select the repository containing your configuration.

    Configure HTTP Traffic

    In the deployment settings:

    • Select HTTP as the traffic type
    • Set the internal port to 80

    Set Environment Variables

    In the environment variables section, add the following:

    VariableValue
    LHC_SECRET_HASHYour generated secret hash
    LHC_DB_HOSTYour database host
    LHC_DB_USERYour database username
    LHC_DB_PASSYour database password
    LHC_DB_NAMEYour database name

    Attach Persistent Volumes

    Add persistent storage:

    Mount PathRecommended SizePurpose
    /var/www/html/var/storage10 GBUploaded files and attachments
    /var/www/html/cache1 GBApplication cache

    Deploy Your Application

    Click Deploy to start the build process. Klutch.sh will:

    • Detect your Dockerfile automatically
    • Build the container image
    • Attach the persistent volumes
    • Start the Live Helper Chat container
    • Provision an HTTPS certificate

    Complete Initial Setup

    Access your instance at https://your-app-name.klutch.sh and complete the web-based setup wizard.

Initial Setup and Configuration

Setup Wizard

The first-time setup wizard guides you through:

  1. Database Configuration: Verify database connection
  2. Admin Account: Create your administrator account
  3. Site Settings: Configure basic site settings
  4. Chat Configuration: Set up default chat behavior

Configuring Chat Widget

After setup, configure your chat widget:

  1. Navigate to System ConfigurationLive Help Configuration
  2. Customize widget appearance:
    • Colors and branding
    • Position on page
    • Greeting messages
    • Offline behavior
  3. Generate embed code for your website

Department Setup

Organize support by department:

  1. Go to SystemDepartments
  2. Create departments (Sales, Support, Billing, etc.)
  3. Configure routing rules
  4. Assign operators to departments

Operator Management

Add support agents:

  1. Navigate to SystemUsers
  2. Create user accounts
  3. Assign departments and permissions
  4. Configure individual operator settings

Embedding on Your Website

Standard Embed

Add the chat widget to your website:

<script>
var LHC_API = LHC_API||{};
LHC_API.args = {
mode:'widget',
lhc_base_url:'https://your-livehelperchat.klutch.sh/',
wheight:450,
wwidth:350,
pheight:520,
pwidth:500
};
(function() {
var po = document.createElement('script');
po.type = 'text/javascript';
po.setAttribute('crossorigin','anonymous');
po.async = true;
po.src = 'https://your-livehelperchat.klutch.sh/design/defaulttheme/js/widgetv2/index.js';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(po, s);
})();
</script>

Page-Specific Configuration

Customize chat behavior per page:

LHC_API.args = {
mode: 'widget',
lhc_base_url: 'https://your-livehelperchat.klutch.sh/',
department: [1], // Specific department
product: 'Premium Plan', // Pass product info
identifier: 'customer_123' // Track customer
};

Chatbot Configuration

Built-in Bot Framework

Configure automated responses:

  1. Navigate to SystemBot
  2. Create response triggers
  3. Set up conversation flows
  4. Configure fallback to human agents

AI Integration

Integrate with AI services:

  • OpenAI/ChatGPT for intelligent responses
  • Custom AI models via webhooks
  • Sentiment analysis for priority routing

Real-Time Features

Node.js Integration

Enable real-time messaging:

  1. Configure Node.js server settings
  2. Update WebSocket URLs
  3. Test real-time connections

Cobrowsing Setup

Enable screen sharing:

  1. Install cobrowsing extension
  2. Configure cobrowsing server
  3. Test with operators

Workflow Automation

n8n Integration

Automate workflows with n8n:

  1. Enable webhooks in Live Helper Chat
  2. Create n8n workflows
  3. Connect to CRM, ticketing, or other systems

Webhook Events

Available webhook triggers:

  • New chat started
  • Chat closed
  • Message received
  • Visitor identified
  • Bot handoff to human

Production Best Practices

Security Recommendations

  • Strong Secrets: Use complex, unique values for LHC_SECRET_HASH
  • Secure Database: Use strong database passwords
  • HTTPS Only: Ensure all connections use HTTPS
  • Access Control: Limit admin access to authorized personnel
  • Regular Updates: Keep Live Helper Chat updated

Performance Optimization

  • Database Tuning: Optimize MySQL for chat workloads
  • Cache Configuration: Enable and configure caching
  • CDN Integration: Use CDN for static assets
  • Resource Allocation: Scale based on concurrent chat volume

Backup Strategy

Protect your chat data:

  1. Database Backups: Regular MySQL backups
  2. File Backups: Back up /var/www/html/var/storage
  3. Configuration Export: Export settings periodically

Troubleshooting Common Issues

Chat Widget Not Loading

Symptoms: Widget doesn’t appear on website.

Solutions:

  • Verify embed code is correct
  • Check for JavaScript errors in console
  • Ensure HTTPS URLs match
  • Test in incognito mode

Real-Time Not Working

Symptoms: Messages delayed or require refresh.

Solutions:

  • Verify Node.js server is running
  • Check WebSocket connections
  • Review firewall rules
  • Test WebSocket endpoints

Database Connection Issues

Symptoms: Application errors about database.

Solutions:

  • Verify database credentials
  • Check database server accessibility
  • Review connection limits
  • Test direct database connection

Additional Resources

Conclusion

Deploying Live Helper Chat on Klutch.sh gives you an enterprise-grade live support platform with complete control over your data. The combination of chat, voice, video, screen sharing, and chatbot capabilities provides everything needed for modern customer support.

With workflow automation, department routing, and extensive customization options, Live Helper Chat scales from small businesses to large enterprises. The self-hosted approach ensures your customer conversations remain private and secure.

Whether you’re providing pre-sales support, technical assistance, or general customer service, Live Helper Chat on Klutch.sh provides a reliable, feature-rich solution that grows with your business.