PHP 5.6 on Ubuntu

Nov 20, 2014
[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 wan 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 more easier to install or upgrade to PHP 5.6.


  • We need to add the PHP 5.6 PPA to our local repository database.
<code class="language- bash">sudo add-apt-repository ppa:ondrej/php5-5.6  
  • Updating our local repository database.
<code class="language- bash">sudo apt-get update  
  • Installing PHP 5.6
<code class="language- bash">sudo apt-get install php5  

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 <code class="highlighter-rouge">php5-extension name extension name

If you already have PHP 5.x and want to upgrade to PHP 5.6 you can run a <code class="highlighter-rouge">dist-upgrade.

<code class="language- bash">sudo apt-get dist-upgrade  

If you like this content, please consider buying me a coffee.

Buy me a coffeeBuy me a coffee

You will get access to contributer exclusive resources and content.

Thank you!

Darryl Dias

I am a student, artist, and author currently living in Florida. My interests range from technology to arts. I am also interested in programming, writing

Analytics by GoSquared