Magento 2 Page not found ( 404 )after unzipping files

Hi Once again the Hope on Digital Startup’s Community.

I’m following the devdocs Magento Installation guide. I have installed the Apache2, Mysql, PHP, PHPMyAdmin and create database instance.

I have downloaded the Magento zip file and extracted to /var/www/html/magento2 in as said in the DevDocs. I can access localhost/phpmyadmin but I cannot accessing the localhost/setup to continue the installation of Magento. The file is still index.php is still there as default as I not touch it at /var/www/html/index.php.

Note that there in html folder at /var/www/html/ there is one folder called magento2 (Containing Magento extracted files) and one index.php file.

I’m New with Installation of Magento Please guide me to Done the Installation. I’ll very Thankful!

By default the Apache Config points to /var/www/html. The folder it points to should contain the Magento 2 files (not a folder containing the files). There are two very simple solutions to choose from:

  1. Move the contents of /var/www/html/magento2/ to /var/www/html/
  2. Change the line in the Apache Config file from /var/www/html to /var/www/html/magento2 and restart Apache for the changes to take effect. (Mentioned in Step 7 of DevDocs)

Whichever method you choose is personal preference, depending on how you like to setup your web servers.

1 Like

Hi DigitalStartup. I’ve extracted the Magento files to /var/www/html and tried to access the localhost/setup. There is showing a blank page.

Note that now in /var/www/html/ there are two files with same name (index) but with different extensions (php and html). index.html was already there in /var/www/html through which i can access the localhost/ and localhost/phpmyadmin.

Please guide me what to do next with the installation process.

I will be Very Thankful to DigitalStartup and Community.

You should remove any files inside /var/www/html that don’t belong to the unzipped files.

Also, make sure that your Permissions are correct (as stated in DevDocs).