How to Upgrade Magento 2.1 Version to Magento 2.4.6 version

In this blog post, Upgrading Magento from version 2.1 to 2.4.6 involves several steps, including updating the codebase, installing any necessary dependencies, migrating data, and adjusting configurations. Here’s an overview of the process.

The latest version features are: 

  • Page Builder 
  • Declarative schema 
  • Asynchronous and Bulk Web API 
  • Multi-Source Inventory 
  • WYSIWYG Editor Upgrade 
  • Cache Management ACL 
  • Google reCAPTCHA and Two Factor Authentication

Step 1: Check Your Requirements

Check whether your system will support the latest version or not by clicking the below link

Technologies Version
Composer 2.2
OpenSearch 2.5
MySQL 8.0
RabbitMQ 3.9
Varnish 7.1
nginx 1.22
AWS MQ 3.9.16
AWS OpenSearch 1.2
Elasticsearch 8.4, 7.17
MariaDB 10.6
PHP 8.1, 8.2
Redis 7.0
Apache 2.4
AWS Aurora (MySQL) 8.0
AWS ElastiCache Redis 6.2

Step 2: Backup Data

Before upgrading to the latest version, You must make a backup of your website.

Step 3: Install Elasticsearch

The latest version needs Elasticsearch, you can install it by the following method if your server is a Linux server.


sudo rpm --install elasticsearch-x.x-x86_64.rpm

If your server is a Windows server, you can Download Elasticsearch.

Step 4: Check Third-Party Extension Compatibility

Once installed, check all your third-party extensions that will support the latest Magento version. 

Step 5: Upgrade

Enabling the maintenance mode. 

php bin/magento maintenance:enable 

Then run upgrade commands. 

composer require magento/composer-root-update-plugin ~2.0 --no-update 
composer update 

php bin/magento setup:upgrade
php bin/magento setup:static-content:deploy -f
php bin/magento setup:di:compile 

php bin/magento maintenance:disable 

If the site will not be visible, check for folder/file permissions and set the regarding file permissions as shown below. 

chmod -R 777 pub var 

And run the commands for clearing the cache and reindexing. 

php bin/magento cache:flush 
php bin/magento indexer:reindex