Blog / How to Enable or Disable Magento Maintenance Mode
May 7, 2025
Need to update your Magento store without affecting your customers’ online experience? That’s where Magento Maintenance Mode comes in. This built-in feature allows you to temporarily disable the front end of your Magento 2 site. Only people using specific IP addresses will have access to your site, allowing them to perform updates, fixes, and testing behind the scenes.
We’ll go through a step-by-step guide to Magento Maintenance Mode, including how to enable/disable it, whitelist IP addresses, and customize your maintenance page. With our tutorial, you’ll be able to easily manage site updates without disrupting your online store’s performance or visibility.
Magento Maintenance Mode is a useful feature that temporarily hides your storefront from visitors, displaying a maintenance page instead. It’s ideal for performing updates, upgrades, or other tasks that require downtime.
While in maintenance mode, only approved IP addresses can access your frontend storefront. You can manage access by specifying exempt IPs through the command line or by editing configuration files like sitemap.xml or the maintenance.flag.
Magento 2 Maintenance Mode plays a crucial role in ensuring a smooth and professional experience for both store owners and customers during site changes. It improves the customer experience and reduces downtime.
Here are the top six benefits of Magento 2 Maintenance Mode.
1. Better User Experience – Magento 2 Maintenance Mode lets you perform updates or upgrades while minimizing the impact on customers. Entering maintenance mode allows you to make changes behind the scenes while displaying a clear, temporary maintenance message to visitors. This ensures shoppers are kept informed and minimizes disruptions, keeping the overall experience smooth and professional.
2. Reduce Downtime – Displaying a maintenance page allows store owners to safely work on their site without exposing customers to errors or unfinished updates. While a site is in Magento 2 Maintenance Mode, visitors will see a clear maintenance message. Developers or admins can continue working behind the scenes using whitelisted IPs. This planned downtime helps prevent customers from seeing broken pages, minimizing the impact on user experience and sales.
3. Better Magento 2 Security – Magento 2 Maintenance Mode acts as a safeguard during critical updates, such as installing security patches. Temporarily restricting access to your site prevents hackers from exploiting weaknesses during the update process. This protects customer data, maintains user trust, and ensures that security remains a top priority. It also allows Magento to use optimized page settings.
4. Better Site Performance – Site owners can optimize their store in maintenance mode without worrying about harming the customer experience. They can easily install updates and new integrations, fix bugs, and test changes. This allows them to improve page performance and provide a better customer experience.
5. Better Communication – A maintenance page clearly informs visitors that the site is down for maintenance. This helps improve customer trust and reduces frustration since visitors understand what is going on and why the site is down.
6. Fewer Errors and Conflicts – Changing a live storefront can cause errors and conflicts. Using Maintenance Mode while making changes improves site stability and helps prevent compatibility issues. Developers will be able to test any changes before the store goes live.

1. Check Maintenance Mode Status – To check the status of Magento Maintenance Mode, use the command line:
php bin/magento maintenance:status
If you receive these command outputs, maintenance mode is not active:
1. Enable Magento 2 Maintenance Mode – To enable maintenance mode, use command line:
php bin/magento maintenance:enable
You should receive the command output:
2. Customize the Maintenance Page – Create a custom Magento custom template by designing a 503.ptml file. We recommend including information like the expected downtime and when the site is expected to come back online.
Place the 503.ptml file in the errors/default folder. This file will not show when your activate maintenance mode.
3. Whitelist Specific IP Address – To whitelist specific IP addresses and grant them access to your website, use the command line:
php bin/magento maintenance:enable –ip=192.168.0.107 –ip=192.168.0.108
Then insert desired IP address to grant specific IP addresses access to your website.
You should receive the command output:
1. Disable Maintenance Mode – Use the command line:
php bin/magento maintenance:disable
You should receive the command output:
Getting the most use out of Magento Maintenance Mode requires following best practices for maintaining your website.
You enable maintenance mode Magento using the command line interface:
php bin/magento maintenance:enable
This command allows you to easily make Magento site updates while minimizing the impact on customers. It also improves Magento downtime management.
You disable maintenance mode Magento using the command line interface:
php bin/magento maintenance:disable
We recommend copying the default page and then adding your own content to create a Magento 2 maintenance page. Copy /vendor/magento/module-backend/view/adminhtml/templates/page/503.phtml and then customize it using HTML or CSS.
Yes, native Magento Maintenance Mode covers the whole website. It’s not possible to take down only a few pages while leaving the rest of the site accessible. However, developers can use custom modules or extensions to show maintenance mode only on specified pages.
No, general visitors cannot access your website while it is in Magento Maintenance Mode. Only people with white-listed IP address will be able to access the site.
You can notify visitors that your website is in maintenance mode by customizing the maintenance page. We recommend including a message that your website is down for maintenance, as well as estimates for when it will go back up..
If your Magento 2 maintenance page does not show up or appears incorrectly, check the code in the /vendor/magento/module-backend/view/adminhtml/templates/page/503.phtml for errors. If you are using a custom template, check the HTML and CSS is that file.
Enable Magento 2 Maintenance Mode to prevent visitors from accessing your site. You can engage this mode using the Magento maintenance mode command line:
php bin/magento maintenance:enable
When you enable maintenance mode in a Magento 1 storefront, your website will display a “temporarily unavailable” message. This allows you to make updates and changes on the backend while preventing visitors from accessing your site. It also improves Magento downtime management.
To enable Magento maintenance mode using a command line interface, first navigate to your Magento root directly. Then run the CLI command:
php bin/magento maintenance:enable
CLI stands for command line interface. Developers use these terminal-based commands to perform various tasks on your webstore without using the web interface.
You can find CLI commands in the bin/magento script in your Magento root directly.
This is one in our ongoing series of Magento Maintenance Tips and Tricks. We’re previously covered other topics including:
At CertiPro, we are experts in all things related to Magento Open Source and Adobe Commerce. We craft, beautiful, easy-to-find websites. We also provide Sage eCommerce integrations, ongoing Magento website maintenance and support services, and ADA compliance services. We are a one-stop shop for all your Magento website needs.
Ready to take your Magento site to the next level? Contact us today for expert solutions that grow your business — from stunning design to seamless integrations and ongoing support.