There is a new version of this tutorial available for Debian 11 (Bullseye).

Install Ioncube Loader For All PHP Modes (CLI, CGI, FCGI And FPM) On Debian Wheezy

This tutorial exists for these OS versions

On this page

  1. Configure PHP
  2. Links

In this tutorial, I will explain the installation of Ioncube Loader on Debian Wheezy so that it can be used in all PHP Modes. If one of the php.ini files does not exist on your server, then this php mode is not installed and you can skip that php.ini file.

Download the latest ioncube loaders with wget and unpack the archive:

cd /tmp
tar xfz ioncube_loaders_lin_x86-64.tar.gz

Move the loaders to /usr/local/ and clean up the /tmp directory

mv ioncube /usr/local/
rm ioncube_loaders_lin_x86-64.tar.gz

Configure PHP

Now edit the php.ini files with an editor like vi or nano:

For mod_php:

vi /etc/php5/apache2/php.ini


vi /etc/php5/cgi/php.ini

For PHP commandline scripts:

vi /etc/php5/cli/php.ini

For scripts running with PHP-FPM

vi /etc/php5/fpm/php.ini

and add the following line right at the beginning of the file(s) (before the [PHP] line):

zend_extension = /usr/local/ioncube/

so the the resulting file looks like this:

zend_extension = /usr/local/ioncube/

; About php.ini   ;
; PHP's initialization file, generally called php.ini, is responsible for
; configuring many of the aspects of PHP's behavior.

Finally restart apache to apply the changes:

service apache2 restart

When you use PHP-FPM, then restart the PHP-FPM pool daemon as well:

service php5-fpm restart

To test that the ioncube loader has been included in the PHP configuration of your website correctly, create a info.php test file with the following content and place it into the web directory of your site:

vi info.php

With the following content:


And open the URL in a web browser, you should see ioncube loader mentioned there:

Please do not forget to delete the info.php file when you dont need it anymore!

Share this page:

1 Comment(s)