{"id":76143,"date":"2026-03-16T18:51:22","date_gmt":"2026-03-16T15:51:22","guid":{"rendered":"https:\/\/cloudspinx.com\/?p=76143"},"modified":"2026-03-16T18:51:22","modified_gmt":"2026-03-16T15:51:22","slug":"how-to-install-php-8-4-on-amazon-linux","status":"publish","type":"post","link":"https:\/\/computingforgeeks.com\/how-to-install-php-8-4-on-amazon-linux\/","title":{"rendered":"How To Install PHP 8.4 on Amazon Linux 2023"},"content":{"rendered":"\n<p>PHP 8.4\u00a0is the latest major release of the PHP programming Language mostly used in the Development of Web Applications. It is the stable release and you can plan to migrate your applications but being aware that some could break especially where old features are deprecated.<\/p>\n\n\n\n<p>In this article we will cover the installation of PHP 8.4 on Amazon Linux 2023 server running either in the Cloud or On-prem infrastructure.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Update Amazon Linux 2023 system<\/h4>\n\n\n\n<p>Update the system before starting the installation of PHP 8.4 on Amazon Linux 2023 server.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo yum -y update<\/code><\/pre>\n\n\n\n<p>Linux updates often comes with newer kernel patches and reboot is required for the system to run in this new release.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo systemctl reboot<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">Install PHP 8.4 on Amazon Linux 2023<\/h4>\n\n\n\n<p>PHP 8.4 is available in in amazonlinux repository together with it&#8217;s extensions. You can confirm this by running the command below:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo yum search php8.4<\/code><\/pre>\n\n\n\n<p>Sample Output:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large has-custom-border\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"394\" src=\"https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-1024x394.png\" alt=\"\" class=\"wp-image-85720\" style=\"border-radius:10px\" title=\"\" srcset=\"https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-1024x394.png 1024w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-300x115.png 300w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-768x296.png 768w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-1536x591.png 1536w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-2048x788.png 2048w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-1092x420.png 1092w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-696x268.png 696w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-Gitea-on-Amazon-Linux-2023-10-scaled-1-1068x411.png 1068w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>To install PHP 8.4 on Amazon Linux 2023 with standard PHP extensions, run the command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo yum install php8.4-{bcmath,cli,common,dba,dbg,devel,ffi,fpm,ldap,modphp,pgsql,mysqlnd,gd,mbstring,tidy,xml,zip}<\/code><\/pre>\n\n\n\n<p>Sample Output:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large has-custom-border\"><img loading=\"lazy\" decoding=\"async\" width=\"565\" height=\"592\" src=\"https:\/\/computingforgeeks.com\/wp-content\/uploads\/2021\/03\/NoSQL-featured-image.png\" alt=\"\" class=\"wp-image-85724\" style=\"border-radius:10px\" title=\"\" srcset=\"https:\/\/computingforgeeks.com\/wp-content\/uploads\/2021\/03\/NoSQL-featured-image.png 565w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2021\/03\/NoSQL-featured-image-286x300.png 286w, https:\/\/computingforgeeks.com\/wp-content\/uploads\/2021\/03\/NoSQL-featured-image-401x420.png 401w\" sizes=\"auto, (max-width: 565px) 100vw, 565px\" \/><\/figure>\n\n\n\n<p>Check PHP version:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$ <mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-luminous-vivid-amber-color\">php --version<\/mark>\nPHP 8.4.6 (cli) (built: Apr  8 2025 19:55:31) (NTS gcc x86_64)\nCopyright (c) The PHP Group\nBuilt by Amazon Linux\nZend Engine v4.4.6, Copyright (c) Zend Technologies<\/code><\/pre>\n\n\n\n<p>Install Apache httpd web server to test PHP scripts execution:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo yum -y install httpd\nsudo systemctl enable --now httpd<\/code><\/pre>\n\n\n\n<p>Create PHP info script inside default apache web root:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo tee \/var\/www\/html\/phpinfo.php > \/dev\/null &lt;&lt;EOF\n&lt;?php phpinfo(); ?>\nEOF<\/code><\/pre>\n\n\n\n<p>Open your web browser and input <code>http:\/\/SERVER_IP\/phpinfo.php<\/code>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large has-custom-border\"><img decoding=\"async\" src=\"https:\/\/computingforgeeks.com\/wp-content\/uploads\/2025\/06\/How-To-Install-PHP-8.4-on-Amazon-Linux-2023-02-scaled-1-1024x626.png\" alt=\"\" class=\"wp-image-85732\" style=\"border-radius:10px\" title=\"\"><\/figure>\n\n\n\n<p>Check available extensions.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$ <mark style=\"background-color:rgba(0, 0, 0, 0);color:#fcb900\" class=\"has-inline-color\">php --modules<\/mark>\nbcmath\nbz2\ncalendar\nCore\nctype\ncurl\ndate\ndba\ndom\nexif\nFFI\nfileinfo\nfilter\nftp\ngd\ngettext\nhash\niconv\njson\nldap\nlibxml\nmbstring\nmysqli\nmysqlnd\nopenssl\npcntl\npcre\nPDO\npdo_mysql\npdo_pgsql\npdo_sqlite\npgsql\nPhar\nrandom\nreadline\nReflection\nsession\nSimpleXML\nsockets\nSPL\nsqlite3\nstandard\ntidy\ntokenizer\nxml\nxmlreader\nxmlwriter\nxsl\nzip\nzlib\n\n&#91;Zend Modules]<\/code><\/pre>\n\n\n\n<p>Refer to the official<a href=\"https:\/\/www.php.net\/releases\/8.4\/en.php\" target=\"_blank\" rel=\"noreferrer noopener\"> PHP 8.4 release page<\/a> for more reading.<\/p>\n\n\n\n<p>Other articles on Amazon Linux:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/computingforgeeks.com\/how-to-install-amazon-linux-2023-on-kvm-using-qcow2-image\/\">How To Install Amazon Linux 2023 on KVM using QCOW2 Image<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/computingforgeeks.com\/install-and-configure-mattermost-server-on-amazon-linux\/\"><\/a><a href=\"https:\/\/computingforgeeks.com\/install-and-configure-mattermost-server-on-amazon-linux\/\">Install and Configure Mattermost Server on Amazon Linux 2023<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/computingforgeeks.com\/install-java-21-openjdk-21-on-amazon-linux\/\">Install Java 21 (OpenJDK 21) on Amazon Linux 2023<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/computingforgeeks.com\/how-to-install-mongodb-8-0-on-amazon-linux\/\">How To Install MongoDB 8.0 on Amazon Linux 2023<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>PHP 8.4\u00a0is the latest major release of the PHP programming Language mostly used in the Development of Web Applications. It is the stable release and you can plan to migrate your applications but being aware that some could break especially where old features are deprecated. In this article we will cover the installation of PHP &#8230; <a title=\"How To Install PHP 8.4 on Amazon Linux 2023\" class=\"read-more\" href=\"https:\/\/computingforgeeks.com\/how-to-install-php-8-4-on-amazon-linux\/\" aria-label=\"Read more about How To Install PHP 8.4 on Amazon Linux 2023\">Read more<\/a><\/p>\n","protected":false},"author":3,"featured_media":161645,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[690,299,47,50,68],"tags":[39170],"class_list":["post-76143","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-dev","category-how-to","category-linux","category-linux-tutorials","category-programming","tag-php-8-4"],"_links":{"self":[{"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/posts\/76143","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/comments?post=76143"}],"version-history":[{"count":0,"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/posts\/76143\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/media\/161645"}],"wp:attachment":[{"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/media?parent=76143"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/categories?post=76143"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/computingforgeeks.com\/wp-json\/wp\/v2\/tags?post=76143"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}