How to install chatwoot on ubuntu vps
Learn how to install chatwoot on ubuntu vps with our step-by-step tutorial.

This article provides a guide for how to install Chatwoot on Ubuntu VPS server.

What is Chatwoot?

Chatwoot is an open-source customer engagement platform that helps businesses manage customer communication across various channels. It acts as a unified inbox for handling customer queries, providing tools to engage with customers more effectively and efficiently.

Key Features

  1. Unified Inbox:
    Manage conversations from multiple channels, including:

    • Email
    • SMS
    • Live chat on websites
    • Social media (Facebook, Twitter, WhatsApp, Instagram)
    • Messaging platforms (Telegram, Slack, etc.)
  2. Real-Time Chat:
    Provide live chat support directly on your website or app, ensuring instant communication with visitors.
  3. Automations and Workflows:
    Automate repetitive tasks like assigning conversations to agents, sending responses, or closing tickets.
  4. Customizable and Scalable:
    Customize workflows, themes, and branding. Being open-source, it allows developers to tweak and expand the functionality to suit business needs.
  5. Multilingual Support:
    Supports multiple languages, making it ideal for global businesses.
  6. Reporting and Analytics:
    Gain insights into customer interactions, agent performance, and key metrics to improve your service.
  7. Role-Based Access:
    Define roles for team members (e.g., admin, agent) and control access to features.
  8. Integrations:
    Seamlessly integrate with other platforms like CRMs, help desks, and automation tools.
  9. Self-Hosted Option:
    You can deploy it on your own infrastructure for complete data control or use their cloud-hosted service.

Who Can Use Chatwoot?

Chatwoot is designed for:

  • Customer Support Teams: To manage inquiries across platforms.
  • Sales Teams: To engage with prospects via live chat or social media.
  • Startups and SMEs: Who need an affordable, flexible customer service solution.
  • Developers: Interested in building or customizing customer engagement tools.

Benefits

  • Cost-Effective: As an open-source solution, it can be self-hosted to reduce operational costs.
  • Enhanced Customer Experience: Centralized and responsive communication leads to improved customer satisfaction.
  • Data Privacy: Self-hosting ensures full control over customer data, adhering to privacy regulations.

Chatwoot competes with other customer support tools like Zendesk, Intercom, and Freshdesk but stands out due to its open-source nature and flexibility.

Pre-requisites

Save 50% off vps server hosting

Supported Linux distribution

Installation of Chatwoot is possible on most Unix environments, but not officially supported.

Storage

The necessary hard drive space largely depends on your usage, the size and number of attachments that you receive through your conversations etc.

CPU

CPU requirements are dependent on the usage and expected workload. Your workload is influenced by factors such as – but not limited to – how active your users are, how many conversations do you receive and the conversation channels which you are using.

The following is the recommended minimum CPU hardware guidance for a handful of example Chatwoot conversation base sizes.

  • 4 cores is the recommended minimum number of cores and supports up to 10,000 conversations a day.
  • 8 cores supports up to 20,000 conversations a day.
  • More conversations? Consider scaling horizontally by adding more application servers.

Memory

Memory requirements are dependent on the usage and expected workload. Your workload is influenced by factors such as – but not limited to – How active your users are, how many conversations do you receive and the conversation channels which you are using.

The following is the recommended minimum Memory hardware guidance for a handful of example Chatwoot conversation base sizes.

  • 4GB RAM is the required minimum memory size and supports up to 10,000 conversations a day.
    • we are always working to reduce the memory requirement.
  • 8GB RAM supports up to 20,000 conversations a day.
  • More conversations? Consider scaling horizontally by adding more application servers.

Note: Add at least 1GB of swap memory to the machine to ensure that the machine doesn’t run out of resources during an upgrade.

Step-by-Step Guide to Install Chatwoot on Ubuntu VPS

Chatwoot is an open-source customer engagement platform that can be self-hosted. Follow this guide to install Chatwoot on Ubuntu VPS.

Step 1: Update and Prepare Your VPS

  1. Log in to Your VPS:
    Use SSH to access your VPS:

    ssh username@your_vps_ip
  2. Update the System:
    Update your Ubuntu package lists and upgrade installed packages.

    sudo apt update && sudo apt upgrade -y
  3. Install Essential Tools:
    Install necessary dependencies like curl, git, and build-essential.

    sudo apt install curl git build-essential -y

Step 2: Install PostgreSQL

  1. Install PostgreSQL:
    Chatwoot requires PostgreSQL as its database.

    sudo apt install postgresql postgresql-contrib -y
  2. Set Up a Database and User for Chatwoot:
    Switch to the PostgreSQL user and create a database and user.

    sudo -i -u postgres psql

    Run the following commands inside the psql shell:

    CREATE DATABASE chatwoot_db; CREATE USER chatwoot_user WITH PASSWORD 'your_secure_password'; ALTER ROLE chatwoot_user SET client_encoding TO 'utf8'; ALTER ROLE chatwoot_user SET default_transaction_isolation TO 'read committed'; ALTER ROLE chatwoot_user SET timezone TO 'UTC'; GRANT ALL PRIVILEGES ON DATABASE chatwoot_db TO chatwoot_user; \q

    Exit the PostgreSQL user:

    exit

Step 3: Install Redis

Redis is used for background job processing and caching.

sudo apt install redis -y
sudo systemctl enable redis
sudo systemctl start redis

Step 4: Install Node.js

  1. Add the NodeSource Repository:
    curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -
  2. Install Node.js and Yarn:
    sudo apt install nodejs -y npm install --global yarn

Step 5: Install Ruby

Chatwoot is built on Ruby on Rails, so Ruby is essential.

  1. Install RVM (Ruby Version Manager):
    sudo apt install gnupg2 -y curl -sSL https://rvm.io/mpapis.asc | gpg --import - curl -sSL https://rvm.io/pkuczynski.asc | gpg --import - curl -sSL https://get.rvm.io | bash -s stable
  2. Add User to RVM group:
    sudo usermod -aG rvm root
  3. Load RVM:
    source /etc/profile.d/rvm.sh
  4. Install Ruby:
    rvm install 3.2.2 rvm use 3.2.2 --default ruby -v

Step 6: Clone Chatwoot Repository

  1. Clone the Repository:
    git clone https://github.com/chatwoot/chatwoot.git cd chatwoot
  2. Install Dependencies:
    bundle install yarn install

Step 7: Configure Chatwoot

  1. Set Environment Variables:
    Create an .env file and populate it with the necessary configuration.

    cp .env.example .env nano .env

    Update the file with your database credentials and other configurations:

    POSTGRES_HOST=localhost POSTGRES_PORT=5432 POSTGRES_USERNAME=chatwoot_user POSTGRES_PASSWORD=your_secure_password POSTGRES_NAME=chatwoot_db
  2. Run Database Migrations:
    rails db:setup

Step 8: Precompile Assets

rails assets:precompile RAILS_ENV=production

Step 9: Start Chatwoot

  1. Start the Application:
    foreman start -f Procfile.dev
  2. Access Chatwoot:
    Open your browser and navigate to http://your_vps_ip:3000.

Step 10: Set Up Reverse Proxy (Optional)

For production deployment, set up a reverse proxy using Nginx.

  1. Install Nginx:
    sudo apt install nginx -y
  2. Configure Nginx:
    Create a new configuration file:

    sudo nano /etc/nginx/sites-available/chatwoot

    Add the following content:

    server { listen 80; server_name your_domain_or_ip; location / { proxy_pass http://localhost:3000; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection 'upgrade'; proxy_set_header Host $host; proxy_cache_bypass $http_upgrade; } }
  3. Enable the Configuration:
    sudo ln -s /etc/nginx/sites-available/chatwoot /etc/nginx/sites-enabled sudo nginx -t sudo systemctl restart nginx
  4. Access the Application:
    Navigate to http://your_ip_address:3000.

Step 11: Secure with SSL (Optional but Recommended)

  1. Install Certbot:
    sudo apt install certbot python3-certbot-nginx -y
  2. Obtain an SSL Certificate:
    sudo certbot --nginx -d your_domain
  3. Verify SSL Setup:
    Access your site at https://your_domain.


Launch 100% ssd ubuntu vps from $1. 99/mo

Conclusion

You now know how to install Chatwoot on Ubuntu VPS. Configure further settings within the Chatwoot dashboard to tailor it to your requirements.

Share this:
Avatar of editorial staff

Editorial Staff

Rad Web Hosting is a leading provider of web hosting, Cloud VPS, and Dedicated Servers in Dallas, TX.
lg