Install Akaunting on Ubuntu 22.04 or 20.04 LTS

Learn the command and steps to install the free open source accounting software – Akaunting on Ubuntu 22.04 LTS Jammy JellyFish to Ubuntu 20.04 LTS Focal Fossa.

If you want to install Akaunting for a demo on a local server or for permanent purposes on a cloud/hosting VPS server then here is the tutorial to guide you on the steps for the installation of Akaunitng on Ubuntu, Debian, and other similar Linux.

Akaunting is free and open-source accounting software that uses PHP & MySQL to run and is available on GitHub. Thus, no need to use any client or the installation of accounting software on every system of a company or home. Any user who wants to use the Akaunting for small and medium business or personal usage can access it locally or remotely with the help of the internet and browser, once installed.

It provides a web interface like some WordPress-based websites and the procedure of its setup is also similar to it. That’s why it is not only user-friendly but also a device too. Yes, we can use it on smartphones and tablets as well.

Steps to Install Akaunting software on Ubuntu 22.04 or 20.04 LTS 

1: Update Ubuntu 22.04 or 20.04

Run the system update command to install the available updates and also to refresh the APT package index cache.

sudo apt update && sudo apt upgrade


2. Install Apache server for Akaunting

We need a web server to run PHP-based web applications such as Akuanting. Hence, let’s install the popular Apache web server on Ubuntu using the given command.

sudo apt install apache2


3. Enable and Start Apache

Once the installation procedure is completed on your server, run the following commands to enable and start the webserver along with system boot.

sudo systemctl enable --now apache2


4. Install the MariaDB server on Ubuntu 22.04 or 20.04

To store financial data created by the Akaunting software, we need some database that would be provided by MariaDB. However, you can also use PostgreSQL and SQLite.

sudo apt install mariadb-server



4. Enable MySQL services

After setting up MySQL, just like Apache, we also have to enable and start this database service at boot level, which means whenever our system reboots, Apache and MySQL services should start automatically.

sudo systemctl enable --now mysql

Once the installation is completed, secure your Database by setting up a root password and removing unnecessary access.

sudo mysql_secure_installation

The given questions will ask by the system, the example of answers is also given below:

Enter current password for root (enter for none): Press ENTER
Set root password? [Y/n]: Y
New password: Set-your-new-password
Re-enter new password: Set-your-new-password
Remove anonymous users? [Y/n] Y
Disallow root login remotely? [Y/n] Y
Remove test database and access to it? [Y/n] Y
Reload privilege tables now? [Y/n] Y


5. Akaunting database setup

Now using the following commands to create a database that we will use in this open-source accounting software. It will be the same for any Linux OS.

Note: Replace the red color text with whatever you want to use. h2smedia is the database name while h2s is the users and your-pass is the password.

sudo mysql
CREATE USER 'h2s'@'localhost' IDENTIFIED BY 'your-pass';
flush privileges;


6. Install PHP 

The install Akaunting, the minimum PHP version we need to set up for this open-source accounting software is PHP 8.0 or higher.

For Ubuntu 22.04, you can simply run the given command to install PHP 8.x version.

sudo apt install php libapache2-mod-php php-bcmath php-common php-imap php-mbstring php-xmlrpc php-soap php-gd php-xml php-intl php-mysql php-cli php-ldap php-zip php-curl


However, For Ubuntu 20.04 will not have the PHP 8.0 version using the default system repository. Therefore to have the latest PHP 8.0 version, we need to add a PPA repo, here are the commands to follow:

sudo apt install software-properties-common
sudo add-apt-repository ppa:ondrej/php -y
sudo apt install php-imagick php8.0-common php8.0-mysql php8.0-gd php8.0-bcmath php8.0-curl php8.0-zip php8.0-xml php8.0-mbstring php8.0-bz2 php8.0-intl

For PHP 8.1 you can replace 8.0 with 8.1 in the above command.


sudo update-alternatives --config php

Select PHP 8.0 as the default system version.

Install 8.0 PHP on Ubuntu 22.04


7. Install Akaunting on Ubuntu 22.04 or 20.04

In this step, we will download the latest release file of the Akaunting free software and then extract the same in the public web folder for further usage.

wget -O
sudo mkdir -p /var/www/akaunting/
sudo apt install unzip
sudo unzip -d /var/www/akaunting/

Now, change the permission of the cloned folder:

sudo chown -R www-data:www-data /var/www/akaunting/

Now give the apache user full read and write permission:

sudo chmod -R 755 /var/www/akaunting/


8. Configure the Apache site configuration file for Akaunting

Here, we will create an Apache site configuration file for Akaunting to tell it where to look at the folder to execute the files and what other things should it follow.

sudo apt install nano
sudo nano /etc/apache2/sites-available/akaunting.conf

Now add the following lines exactly as they are here including space and break:

Replace the red text with your domain or values.

<VirtualHost *:80>
ServerAdmin localhost
DocumentRoot /var/www/akaunting/

<Directory /var/www/akaunting/>
Options +FollowSymlinks
AllowOverride All
Require all granted

ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined


To save and exit the nano editor, press: the Ctrl+X keys and type: Y, and then hit the Enter button.

Enable the configuration and rewrite modules.

sudo a2ensite akaunting.conf
sudo a2enmod rewrite
sudo a2dissite 000-default.conf

Finally, restart the apache to make the changes into effect.

sudo systemctl restart apache2


9: Setup Akaunting Dashboard

Now, that everything is ready, go to your browser and open the server IP address or domain name (if you are installing it on cloud or VPS hosting).

Here, we are installing Akaunting for a demo on our local server, thus we are using the local IP address of the same.



As you point the domain or IP to access the server, a setup page of the Akaunting will open. First, select the language in which you want to install it, by default it will be English.

Install Akaunting software on Ubuntu 22.04 LTS

Add the details of the MySQL database which we have created in this article.

Add Database in Akaunting

Add the details of the company along with the admin email and password which will be used to access this free accounting software from anywhere.

Create Admin Account on Akaunting

Add your company and Tax details. To get the API key click on the link, create an Akaunting account, and copy the API to paste in.

API Key get Akaunting ubuntu 20.04

Finally, the Dashboard of the software will be in front of you. Now, start performing your financial calculations, creating invoices, adding bills, managing cash flow, expense tracking, and more…

New Invoice of Akaunting Inventory Management Akaunting ubuntu 22.04 Akaunting Invoice

To know more about the setting of this open source accounting software, refer to the official documentation page.


Other Articles:

How to install Supertuxkart Game on Ubuntu 22.04
Install Miniconda on Ubuntu 22.04 LTS Jammy Linux
How to Install WordPress on Ubuntu 22.04 LTS…
Install Sensu Go Monitoring on Ubuntu 22.04 or 20.04
Install Metasploit Framework on Ubuntu 22.04 LTS Jammy



Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.