Magento extensions improve your store’s appearance and add functionalities. To add a new extension, you must ensure that it is compatible with your current Magento version.
Installing an extension that isn’t compatible with your Magento version can lead to a broken store and expensive downtime. Adobe gives you many ways to check the Magento version of your installation.
This guide will show you different ways to check the Magento version of your online store. In addition, we’ll account for different scenarios when some methods aren’t available for you to find the version number.
Check Magento Version from URL
The easiest way to check the Magento version is by adding /magento_version at the end of its domain URL.
For example, here’s how to check which Magento version Helly Hansen, a major sports retailer, uses on their website.
If you go to: https://www.hellyhansen.com/magento_version, it returns with this response.
Magento/2.4 (Enterprise)
Once you access this URL, your browser sends a GET request to the “Magento_Version” module, which looks for the Magento version and provides you with a brief response.
But this method may not always work. Sometimes, you may see a 404 error with this approach. Many companies disable the “Magento_Version” module to avoid disclosing their Magento version.
Having details like platform type and version open to the public makes a hacker’s job easier as they can exploit known vulnerabilities of that Magento version.
If you can’t find the Magento version of your competitor’s store, you can use the following method.
Check Magento Version with an Online Tool
Checking the Magento version with an online tool is quick and easy if the URL method doesn’t work.
Many services help you find the current version, but Mage Report works well. It’s a free online tool that generates security reports for Magento websites and lists their Magento version.
For example, here’s a report for Helly Hansen’s website.
You can see that this company uses the latest version of Magento Enterprise Edition, or Adobe Commerce, as of March 2022.
To find the current version of a website, you only need to enter its URL on Mage Report’s website and hit the Scan button. Then, scroll down to find the Magento version once the report is generated.
Check Magento Version in Admin Dashboard
If you have access to the Magento admin panel, you can find which Magento version your site uses by logging in to your admin user account.
You’ll see the Magento version on the bottom right-hand side of the page. This information is available on all backend pages.
4. Check Magento Version using CLI
Besides the above ways, you can also check the Magento version using the command line interface. You only need to log in to your Magento server, go to the project root directory, and execute the following command.
php bin/magento --version
Response:
Magento CLI 2.4.0
To find out if the Magento store is using Magento Open Source (formerly Community Edition) or Adobe Commerce (formerly Enterprise Edition), run the following command:
composer licenses | grep Name:
Response:
Name: magento/project-community-edition
5. Check Magento Version in composer.json File
You can also find the Magento version in the composer.json file. The Magento composer.json file is located in the root directory, and it lists all the dependencies of the Magento application.
You can read Adobe’s guide to learn more about the Magento composer.json file.
Here’s how to check the Magento version using the composer.json file from the command line:
- Log in to your Magento server via SSH and go to the project root directory.
- Run the following command to check the Magento version in the composer.json file:
cat composer.json
You’ll see an output similar to the one below:
{ "name": "magento/project-community-edition", "description": "eCommerce Platform for Growth (Community Edition)", "type": "project", "license": [ "OSL-3.0", "AFL-3.0" ], "config": { "preferred-install": "dist", "sort-packages": true }, "version": "2.4.0", ...... }
6. Check Magento Version in composer.lock File
Besides the composer.json file, you can also check the Magento version of your store using the composer.lock file. Similar to the composer.json file, the Magento composer.lock file is located in the project root directory.
The composer.json file lists your project’s required libraries and versions (dependencies). On the other hand, the composer.lock file lists the dependencies currently installed, i.e., the locked dependencies, along with the exact versions.
You can read Adobe’s guide for more information about the Magento composer.lock file.
Follow these steps to check the Magento version using the composer.lock file:
- Log in to your Magento server and go to the project root directory.
- Execute the following command to check the Magento version in the composer.lock file:
nano composer.lock
- Use the down arrow button to scroll through the content of the composer.lock file and locate the following section to identify your Magento version:
{ "name": "magento/product-community-edition", "version": "2.4.3", "source": { "type": "git", "url": "https://github.com/2tvenom/CBOREncode.git", "reference": "42aedccb861d01fc0554782348cc08f8ebf22332" }