How To Install PHP 7.3 On Ubuntu 20.04

The Hypertext Preprocessor commonly known as PHP, is a powerful, PHP is an open-source server-side scripting language which has been widely adopted for the creation of dynamic web pages. PHP is secure, fast, simple, efficient, flexible and a loosely typed scripting language.

Through this tutorial, i am going to show you how to install PHP 7.3 on ubuntu 20.04.

How To Install PHP 7.3 On Ubuntu 20.04

Just follow the below given steps to install PHP 7.3 on ubuntu 20.04:

  • Step 1 – Update System Dependencies
  • Step 2 – Install PHP 7.3
  • Step 3 – Test Installed PHP Version

Step 1 – Update System Dependencies

Installing the PHP on Ubuntu with PHP Version 7.3. First update the apt package :

sudo apt-get update

Step 2 – Install PHP 7.3

Before install PHP 7.3, We’ll add the PPA For PHP 7.3

sudo apt-get install python-software-properties -y  

sudo add-apt-repository ppa:ondrej/php

Install The PHP On Ubuntu with the below command:

sudo apt-get install php7.3

Step 3 – Test Installed PHP Version

Just use the below given command to check the PHP version installed on your server :

php -v

Install PHP 7.3 Extensions

 sudo apt-get install php7.3-<extension-name>

See example below

sudo apt-get install php7.3-fpm  php7.3-curl php7.3-mysql \ php7.3-xml php7.3-zip php7.3-gd

Conclusion

In this tutorial, You have learned how to install PHP 7.3 on your Ubuntu 20.04 server with using the PPA. 

Leave a Comment