PHP 5.6 is the latest stable version of PHP available. The latest stable version of PHP available for Ubuntu is PHP 5.5.x, If you want to PHP 5.6 or upgrade your existing PHP 5.x install to 5.6 follow this guide. PHP 5.6 can be installed using a PPA which makes it even easier to install or upgrade to PHP 5.6.


  • We need to add the PHP 5.6 PPA to our local repository database.
sudo add-apt-repository ppa:ondrej/php5-5.6  

Updating our local repository database.

sudo apt-get update  
Code language: JavaScript (javascript)

Installing PHP 5.6

sudo apt-get install php5  
Code language: JavaScript (javascript)

All the extension that were available for PHP 5.x is available for PHP 5.6 and can be installed in the same old way as all other PHP extensions are installed using php5-extension name extension name

If you already have PHP 5.x and want to upgrade to PHP 5.6 you can run a dist-upgrade.

sudo apt-get dist-upgrade  
Code language: JavaScript (javascript)

I compiled a list of software and services that I use to improve my workflow, here is the link to the list.

Darryl Dias

I’m Darryl. I’m a 3D Artist, Programmer and Linux enthusiast. On this site I share my insights, tips and tricks, tutorials, methods and best practices.