There are a number of Magento developers who started upgrading their client’s stores and providing the best Magento development services. But the beginners are still searching for a step by step guide to upgrading Magento version from 2.3.x to 2.4.0. In this post, Our Magento experts have discussed how can you upgrade Magento 2.3 store in the Magento 2.4.0. keep your store safe and up to date play an important role for your Magento store we hope this post is very helpful for you.
Is Magento 2.4.0 a really better version of Magento or you have a different point of view? Click To TweetHere we will show you step by step how to upgrade the Magento version from 2.3.x to 2.4.0:
Go to Your Root Directory
Step 1: Take backup your current composer.json file using command line
1 |
cp composer.json composer.json.backup |
Step 2: For Magento Open Source:
1 2 3 |
composer require magento/product-community-edition=2.4.0 --no-update composer require magento/module-bundle-sample-data:100.1.0 magento/module-widget-sample-data:100.1.0 magento/module-theme-sample-data:100.1.0 magento/module-catalog-sample-data:100.1.0 magento/module-customer-sample-data:100.1.0 magento/module-cms-sample-data:100.1.0 magento/module-catalog-rule-sample-data:100.1.0 magento/module-sales-rule-sample-data:100.1.0 magento/module-review-sample-data:100.1.0 magento/module-tax-sample-data:100.1.0 magento/module-sales-sample-data:100.1.0 magento/module-grouped-product-sample-data:100.1.0 magento/module-downloadable-sample-data:100.1.0 magento/module-msrp-sample-data:100.1.0 magento/module-configurable-sample-data:100.1.0 magento/module-product-links-sample-data:100.1.0 magento/module-wishlist-sample-data:100.1.0 magento/module-swatches-sample-data:100.1.0 magento/sample-data-media:100.1.0 magento/module-offline-shipping-sample-data:100.1.0 --no-update |
Step 3: Update Magento dependencies:
1 |
composer update |
Step 4: If authentication keys required then (step 4 skip if not required)
- Go to Magento Marketplace.
- Log in to the Magento Marketplace. If you don’t have an account, click Register.
- Click your account name in the top-right of the page and select My Profile.
- Click Access Keys in the Marketplace tab.
- Click Create a New Access Key. Enter a specific name for the keys (e.g., the name of the developer receiving the keys) and click OK.
New public and private keys are now associated with your account that you can click to copy. Save this information or keep the page open when working with your Magento project. Use the Public key as your username and the Private key as your password.
Step 5: Manually remove the var/cache, var/page_cache, and var/generation directories.
1 |
rm -rf var/cache/* var/page_cache/* var/generation/* |
Step 6: Run Command for Upgrade Magento and Compile :
1 2 |
php -dmemory_limit=5G bin/magento setup:upgrade php -dmemory_limit=5G bin/magento setup:di:compile |
Step 7: Deploy Static Content, flush ad clean cache using this command:
1 2 3 |
php -dmemory_limit=5G bin/magento setup:static-content:deploy -f php -dmemory_limit=5G bin/magento cache:flush php -dmemory_limit=5G bin/magento cache:clean |
Step 8: You should run reindex for better performance after upgrading.
1 |
php -dmemory_limit=5G bin/magento indexer:reindex |
If you have any problem related to the Magento upgrade then you are always free to contact us for asking any questions related to this article and the eCommerce Magento store. We are always available to help you at any time. If you also want to know more about the upgrade Magento 2.4.0 then can click this link below.
Thank You! 🙂
Magento Expert
If You are aware of magento and its updates please try to check your knowledge.