CYBER WEEK SALE - 50% OFF ALL HOSTING PLANS
50% OFF ALL NEW PLANS

Dolibarr logo

Dolibarr is an open source software package for companies of any size, foundations, or freelancers. It includes different features for ERP (Enterprise Resource Planning) and CRM (Customer Relationship Management) and can be extended further by different modules. Dolibarr can be installed on our servers.

This guide has been tested with Dolibarr version 21.

Prerequisites

Before you install Dolibarr, there are a few settings to configure on your hosting account.

  • SSH access and Network tools must be enabled for your account via the hosting Control Panel > SSH Access section.
  • The PHP version should be PHP 8.1 or later for the domain/subdomain where you wish to use Dolibarr. You can learn more on how to change your PHP settings in our Changing PHP settings article.
  • Create a MySQL 8 database (e.g. example_dolibarr) and user (e.g. dolibarruser) for the Dolibarr application. For security reasons, MySQL databases and users can be created only through the hosting Control Panel. Detailed instructions on the process are available in our Creating a MySQL database/user article. Make sure that the MySQL user is associated with the database by following the instructions from our Associating a MySQL user with a database article.
  • To have Dolibarr working via HTTPS, install an SSL certificate on the server for your domain or subdomain, and force HTTPS for it via the hosting Control Panel > SSL/HTTPS section > Force HTTPS subsection.

Installation

  1. The easiest way to install the files of Dolibarr is with Git, so connect to your account via SSH, and navigate to the directory of the domain/subdomain where you wish to use Dolibarr (e.g. ~/www/www for your main domain):

    cd /home/$USER/www/www
  2. Download the Dolibarr files with Git:

    git clone https://github.com/Dolibarr/dolibarr/
    This will upoad the Dolibarr files in the ~/www/www/dolibarr directory of your account.

  3. The public files of Dolibarr are located in its htdocs folder, so you should access the hosting Control Panel > Subdomains section and change the Document Root for the Dolibarr domain/subdomain to that folder. If you wish to use Dolibarr on your main domain, set the Document Root for the www subdomain to /www/www/dolibarr/htdocs.

  4. Set the default MySQL socket for PHP to MySQL 8 instead of MySQL 5 by adding the following line to a .user.ini file in the htdocs folder:

    mysqli.default_socket=/tmp/mysql8.sock
    If Dolibarr is installed on your main domain, you can make this change with the following SSH command:

    echo 'mysqli.default_socket=/tmp/mysql8.sock' >> /home/$USER/www/www/dolibarr/htdocs/.user.ini

  5. Access the Dolibarr setup wizard by opening the install folder of the domain/subdomain of Dolibarr (e.g. http://example.com/install), and follow the listed steps.

  6. Enter the following details on the  Configuration file step under Dolibarr Database:

    Dolibarr Database

    • Database name - Enter the name of the MySQL 8 database you created earlier for Dolibarr (e.g. example_dolibarr).
    • Login - Enter the name of the MySQL 8 user you created earlier for the Dolibarr database (e.g. dolibarruser).
    • Password - Enter the password for the MySQL 8 user.

    Leave the remaining fields with their default values, unless you wish to customize your Dolibarr installation.

  7. Proceed further, and on the Administrator login creation page, enter a username and password for the main Dolibarr administrator.

  8. After the Dolibarr administrator user is created, you should create a file named install.lock in the htdocs directory of Dolibarr to prevent unauthorized access to the Dolibarr installation script. If Dolibarr is installed on your main domain, you can create the file using this SSH command:

    touch /home/$USER/www/www/dolibarr/htdocs/install.lock

  9. That is it. Dolibarr should now be accessible at your domain/subdomain (e.g. http://example.com/).

    Dolibarr Login