unisntall php code example Example: uninstall php ubuntu 18.04 Click to copy$ sudo apt-get purge php7.* $ sudo apt-get autoclean $ sudo apt-get autoremove