Install IonCube Loader for PHP on Nginx-Ubuntu Server

PHP based software often need IonCube Loader installed on server to function properly. In fact they can’t be installed if the server doesn’t have IonCube Loader installed. IonCube Loader is used to load encrypted PHP files on the server. And today i’m going show you how to install IonCube Loader on Ubuntu 14.04 VPS.

As I said before, IonCube Loader is a php module that is used to load PHP files encrypted with IonCube Encoder. Most paid software developers use IonCube to encrypt their code. When you purchase one of those software, you’ll need IonCube Loader installed on your server to use it.

Installing IonCube Loader on Nginx-Ubuntu server is fairly easy. Follow this guide carefully and you’ll have IonCube Loader on your server in matter of few minutes.

Before we start, i’m going to assume that you already have your VPS setup with PHP, MySQL and Nginx. If not, I suggest you do it now.

First, you need add some rules to Nginx default virtual host file,

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

Delete everything on that file (Ctrl+K) and paste following lot,

server {
        listen 80 default_server;
        listen [::]:80 default_server ipv6only=on;

        root /usr/share/nginx/html;
        index index.php index.html index.htm;

        server_name localhost;

        location / {
                try_files $uri $uri/ =404;

        location ~ .php$ {
                include fastcgi_params;
                fastcgi_pass unix:/var/run/php5-fpm.sock;

Save and close (Ctrl+X then Enter) file. Then restart Nginx,

sudo service nginx restart

Navigate to Nginx default directory,

cd /usr/share/nginx/html

Now download and extract matching IonCube Loader package for your system.

sudo wget
sudo tar xvfz ioncube_loaders_lin_x86.tar.gz
sudo wget
sudo tar xvfz ioncube_loaders_lin_x86-64.tar.gz

Now point you browser to following url. Replace server_ip with your server’s ip address.


You’ll see a page similar to this,

Setup is pretty easy from here. You just have to do what the loader wizard suggests. As you can see from the above image, it’s asking me to copy,




Yours may be different. Please change following command accordingly.

sudo cp /usr/share/nginx/html/ioncube/ /usr/lib/php5/20121212

Scroll down the ionCube Loader Wizard page and you’ll see Installation Instructions section with 5 steps. You’ve already completed first and second steps. So let’s move to the third step. It’s asking you to save a file in /etc/php5/fpm/conf.d directory. So save that file to your computer first. But instead of uploading it to the server, you should copy it’s content to the server’s php.ini file. If you upload it to the server as wizard says, you’ll end up with getting a 502 Bad Getaway error. So open loaded php.ini file,

sudo nano /etc/php5/fpm/php.ini

Now open downloaded file and copy-paste content of it to the end of php.ini file (When I say “end” I mean after the line that reads ; End:). Mine looked like this,

zend_extension = /usr/lib/php5/20121212/

Save and close the file. Forth step is to restart the server. That shouldn’t be so hard to do,


Fifth step is to click some link provided by the ionCube Loader Wizard. Click it and wait for few seconds. If you followed this tutorial correctly, you’ll see “Loader Installed Successfully” on the next page. If not, use the comments section below 😉

If everything went nicely, final step is to remove ionCube Loader Wizard from the server. Following command should take care of that,

sudo rm -rf /usr/share/nginx/html/ioncube

Now you have a Ubuntu 14.04 VPS with PHP, ionCube Loader, MySQL and NGINX. Enjoy it!

Show More


Hey!! I'm Tharindu. I'm from Sri Lanka. I'm a part time freelancer and this is my blog where I write about everything I think might be useful to readers. If you read a tutorial here and want to hire me, contact me here.

Related Articles


  1. hey, i have a problem during installation.I use ubuntu 14.4 on a rootserver, copied the content to the dirs, setup the conf with the extension but i get all the time this Error : Please note also the following issue:

    Some functions are disabled through disable_functions. This may affect the operation of this Loader Wizard.

    Normaly it is installed, but he tell me that is no loader installed if i press : “click here to test the Server” but i have try out many things.1. put this conffile 20-ioncube to the php-fpm conf.d dir. or directly in my php.ini but i got no luck. im realy pissed off 🙂 can pls help me, thx.

Leave a Reply

Your email address will not be published. Required fields are marked *