How to Install Magento 2 on the localhost with XAMPP?

Installing Magento 2 isn’t an easy process. So we’ve prepared a step-by-step guide on how you can install Magento 2 with the help of XAMPP. Let’s start.

How to run Magento in localhost

Step 1. First of all, you need to make sure that you meet all the system requirements of Magento 2.

Step 2. Then, download and install XAMPP.

Step 3. Go to the official Magento website and download the setup package.

Step 4. Navigate to the xampp/htdocs and create the Magento folder.

Step 5. Unpack the archive in the just created folder.

Step 6. Next, open the XAMPP Control Panel and click the Config button in the Apache line.

Step 7. Select the PHP (php.ini) option from the dropdown.

Step 8. In the opened document, you need to find the extension=php_intl.dll and extension=php_xsl.dll lines and delete the ; symbol at the beginning.

Step 9. Then, go back to the window with XAMPP Control Panel and install the needed for Magento 2 services: Apache and MySQL.

Step 10. The next thing that you need to do to install Magento 2 on the XAMPP server is moving to localhost/phpMyAdmin and creating a database with the name magento2.

Step 11. Enter localhost/magento2 in your browser and click on the Agree and Setup Magento button.

Step 12. Then, you will need to finish 6 steps of the Magento 2 installation. The first step is the Readiness Check. Run the test and, after getting the success message, click on the Next button.

Step 13. Next, you will see the Add Database step. Here you need to fill in the database server host, username, password, name, and table prefix if needed. When you are ready, click the Next button.

Step 14. In step 3 of the Magento 2 installation, you need to enter your Web Configuration. For this fill in the Your Store Address and Magento Admin Address fields. Go on to the next step.

Step 15. In the Customize Your Store step, select the store default timezone, currency, and language. When you are ready, click the Next button.

Step 16. The last thing that you need to specify is your admin account. In the Create Account step, you need to fill in the following fields:

  • New Username;
  • New Email;
  • New Password;
  • Confirm Password.

Step 17. In the final Install step, click on the Install Now button. The installation process may take time, but once it is done, you will see the success message.

Step 18. Then go to your browser and enter localhost/magento and localhost/magento/admin. Check if everything displays correctly.

If you got the blank page in your admin and Magento not installing localhost, check out how to fix this issue.

We hope that this guide will help you complete the Magento 2 installation via XAMPP successfully.

If your technical skills aren't enough for making the work correctly and hiring an outsource development team is too timely and risky, we offer you our installation service, as well as custom development. Our Magento-certified specialists will be happy to make the work for you. 

How can we help you?

Didn’t you find the answer to your question? We are always happy to help you out.