{"id":15833,"date":"2025-10-10T17:45:17","date_gmt":"2025-10-10T12:15:17","guid":{"rendered":"https:\/\/www.skynats.com\/?p=15833"},"modified":"2025-10-10T17:45:19","modified_gmt":"2025-10-10T12:15:19","slug":"how-to-install-prestashop-8-1-6-on-ubuntu-24-04","status":"publish","type":"post","link":"https:\/\/www.skynats.com\/blog\/how-to-install-prestashop-8-1-6-on-ubuntu-24-04\/","title":{"rendered":"How to Install PrestaShop 8.1.6 on Ubuntu 24.04"},"content":{"rendered":"\n<ul class=\"wp-block-list\">\n<li>PrestaShop is a popular open-source e-commerce platform built with PHP.<br><\/li>\n\n\n\n<li>It offers a flexible, feature-rich solution to create and manage online stores.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-nbsp-update-your-system\"><strong>&nbsp;Update Your System<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Start by updating all packages:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>apt update &amp;&amp; sudo apt upgrade -y<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-install-apache-web-server\"><strong>\u00a0Install Apache Web Server<\/strong><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code> apt install apache2 -y\nsystemctl enable apache2\nsystemctl start apache2<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">To verify it&#8217;s running:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code> systemctl status apache2<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-install-mysql-or-mariadb\"><strong>\u00a0Install MySQL (or MariaDB)<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Install MySQL server:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">apt install mysql-server -y<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now log in and create your PrestaShop database and user:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mysql<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Inside the MySQL shell, run:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>CREATE DATABASE prestashop_db DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;\nCREATE USER 'ps_user'@'localhost' IDENTIFIED BY 'Password123!';\nGRANT ALL PRIVILEGES ON prestashop_db.* TO 'ps_user'@'localhost';\nFLUSH PRIVILEGES;\nEXIT;<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading has-small-font-size\" id=\"h-install-php-8-1-and-required-extensions\"><strong>\u00a0Install PHP 8.1 and Required Extensions<\/strong><\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/ubuntu.com\/\" target=\"_blank\" rel=\"noopener\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-secondary-color\">Ubuntu<\/mark><\/a> 24.04 ships with PHP 8.3, but PrestaShop only supports up to PHP 8.1.\u00a0<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Add the PHP 8.1 PPA:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>apt install software-properties-common -y\nadd-apt-repository ppa:ondrej\/php -y\napt update<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-install-php-8-1-modules\"><strong>Install PHP 8.1 modules:<\/strong><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>apt install php8.1 php8.1-cli php8.1-common php8.1-mysql php8.1-gd php8.1-curl php8.1-mbstring php8.1-xml php8.1-intl php8.1-zip php8.1-bcmath libapache2-mod-php8.1 unzip curl -y<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-set-php-8-1-as-the-default\"><strong>Set PHP 8.1 as the default:<\/strong><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code> update-alternatives --set php \/usr\/bin\/php8.1<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Verify the version:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>php -v<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\"><strong>Download and Extract PrestaShop 8.1.6<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Download the latest compiled release, not the source code:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>wget https:\/\/github.com\/PrestaShop\/PrestaShop\/releases\/download\/8.1.6\/prestashop_8.1.6.zip\nunzip prestashop_8.1.6.zip<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This will create a prestashop.zip file inside. Extract it:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>unzip prestashop.zip -d prestashop\nmv prestashop \/var\/www\/html\/prestashop<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Set the right permissions:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>chown -R www-data:www-data \/var\/www\/html\/prestashop\nchmod -R u+rw \/var\/www\/html\/prestashop<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-configure-apache-virtual-host\"><strong>Configure Apache Virtual Host<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Create a new site config:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>vim \/etc\/apache2\/sites-available\/prestashop.conf<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Paste the following:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;VirtualHost *:80>\n    ServerAdmin webmaster@localhost\n    DocumentRoot \/var\/www\/html\/prestashop\n    ServerName localhost\n\n    &lt;Directory \/var\/www\/html\/prestashop\/>\n        Options Indexes FollowSymLinks\n        AllowOverride All\n        Require all granted\n    &lt;\/Directory>\n\n    ErrorLog ${APACHE_LOG_DIR}\/prestashop_error.log\n    CustomLog ${APACHE_LOG_DIR}\/prestashop_access.log combined\n&lt;\/VirtualHost><\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading has-small-font-size\" id=\"h-enable-the-site-and-rewrite-module\"><strong>Enable the site and rewrite module:<\/strong><\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>a2ensite prestashop\na2enmod rewrite\nsystemctl reload apache2<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-install-prestashop-via-browser\"><strong>\u00a0Install PrestaShop via Browser<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Open your browser and navigate to:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>http:&#47;&#47;your-server-ip\/<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">You\u2019ll be guided through:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Database configuration:<\/li>\n\n\n\n<li>Language selection<\/li>\n\n\n\n<li>License agreement<\/li>\n\n\n\n<li>System compatibility<\/li>\n\n\n\n<li><strong>DB Name<\/strong>: prestashop_db<\/li>\n\n\n\n<li><strong>User<\/strong>: ps_user<\/li>\n\n\n\n<li><strong>Password<\/strong>: StrongPassword123!<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">After installation finishes, you&#8217;ll see a success screen.<\/p>\n\n\n\n<h3 class=\"wp-block-heading has-small-font-size\" id=\"h-post-installation-cleanup\"><strong>Post Installation Cleanup<\/strong><\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Delete the install folder:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo rm -rf \/var\/www\/prestashop\/install<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading has-small-font-size\" id=\"h-conclusion\"><strong>Conclusion<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>For production, consider enabling HTTPS and firewall rules for added security.<\/li>\n\n\n\n<li>You now have a ready-to-use, scalable e-commerce platform for your business.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">If you need expert assistance to install PrestaShop on Ubuntu 24.04, our skilled team at Skynats is ready to help. With our reliable <a href=\"https:\/\/www.skynats.com\/linux-server-management\/\">Linux server management services<\/a>, we ensure a smooth installation and optimized server performance for your PrestaShop store. Contact us today for professional support!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp;Update Your System Start by updating all packages: \u00a0Install Apache Web Server To verify it&#8217;s running: \u00a0Install MySQL (or MariaDB) Install MySQL server: apt install mysql-server -y Now log in and create your PrestaShop database and user: Inside the MySQL shell, run: \u00a0Install PHP 8.1 and Required Extensions Ubuntu 24.04 ships with PHP 8.3, but [&hellip;]<\/p>\n","protected":false},"author":12,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[1132,1133,1010,1131,899],"class_list":["post-15833","post","type-post","status-publish","format-standard","hentry","category-blog","tag-install-prestashop","tag-install-prestashop-on-ubuntu-24-04","tag-linux-server-management-services","tag-prestashop-8-1-6","tag-ubuntu-24-04"],"_links":{"self":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts\/15833","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/users\/12"}],"replies":[{"embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/comments?post=15833"}],"version-history":[{"count":1,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts\/15833\/revisions"}],"predecessor-version":[{"id":15838,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts\/15833\/revisions\/15838"}],"wp:attachment":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/media?parent=15833"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/categories?post=15833"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/tags?post=15833"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}