I am trying to install Magento version 2.4.0 in my localhost by running URL in the browser directly.

Can anyone tell me how can i install it?

What to do next from here.

Please help me to solve this issue.

I tried my best but it did not install so far.



From Magento version 2.4.0, you can not install Magento using URL. you have to use Command Line Interface for this.

Also, MySql has been replaced with Elastic Search for catalog search so you have to install Elastic Search in your localhost first.

Check this link for System Requirements: https://devdocs.magento.com/guides/v2.4/install-gde/system-requirements-tech.html

If you have already installed Elastic Search in your localhost then you can run below command from root directory of your project in terminal

sudo php bin/magento setup:install --base-url=http://localhost/magento240/ \
--db-host=localhost --db-name=magento240 --db-user=root --db-password=mysql123 \
--admin-firstname=Magento --admin-lastname=User --admin-email=user@example.com \
--admin-user=admin --admin-password=admin123 --language=en_GB \
--currency=GBP --timezone=Europe/London --use-rewrites=1 \
--search-engine=elasticsearch7 --elasticsearch-host= \

You can also use --disable-modules=Magento_TwoFactorAuth argument in the command to disable the Two Factor Auth module because by default Magento use Two Factor Authentication for admin login.

You can disable it from app/etc/config.php later after installing magento by changing value from 1 to 0 for Magento_TwoFactorAuth

Then run below commands:

php bin/magento setup:upgrade

php bin/magento setup:di:compile

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.