Skip to content

A list of useful commands for Magento 2

In this blog, I am writing some Magento 2 Useful Commands List.

Here the list of most important SSH / CLI commands for Magento 2. To use these commands you will need to have SSH access to your server or use the Command Line for local access.

Setup Upgrade:

  • In case you want to keep pub/static files while installing/updating database, apply the following command:

Static Content Deploy  (Use -f for force deploy on 2.2.x or later)

Static Content Deploy For Particular Language

Cache Clean

Cache Flush


View the list of indexers

View indexer status

Show the mode of all indexers

Enable / Disable module

Uninstall Module

Check Current Mode

Change Developer / Production Mode

Enable Maintenance Mode

Deploy static content for specific themes

Run the single-tenant Compiler

Unlock Admin user

Enable maintenance mode for all clients except and

To clear the list of IPs.

Disable Maintenance Mode

Install Magento 2

Create Admin User

Enable / Disable hints for frontend template

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *

Share via
Copy link
Powered by Social Snap