How Can We Help?
< All Topics
Print

Managing Maintenance Mode in Drupal: Enabling and Disabling Guide

a) How do I enable maintenance mode using the admin interface in Drupal ?

1. First, navigate to Configuration, select Development, and click Maintenance Mode (admin/config/development/maintenance) in the Manage administrative menu to access the maintenance mode page.

2. After that, fill in the fields as shown below.

Field name Explanation Example value
The site should be placed into maintenance mode. Enable maintenance mode. Checked
The message is displayed during maintenance mode. Enabling this mode displays this information to website visitors, allowing variables like @site to be used in messages @site is currently under maintenance, but it is expected to be back up soon. Thank you for your patience.

3. Then, click Save Configuration.

4. Finally, access it from a different browser, and if it doesn’t work, clear your cache to ensure the website is in maintenance mode.

drupal

b) How do I disable maintenance mode using the admin interface in Drupal ?

1. First, navigate to Configuration, select Development, and click on Maintenance Mode (admin/config/development/maintenance) in the Manage administrative menu to access the Maintenance Mode page.

2. After that, fill in the fields as shown below.

Field name Explanation Example value
The site should be placed into maintenance mode Disable maintenance mode Unchecked
The message is displayed during maintenance mode This field is not needed when disabled, and it can be left blank

3. Then, click Save Configuration.

4. Finally, access it from a different site or browser, and if it doesn’t work, clear your cache to confirm the site’s status.

c) How do I enable or disable maintenance mode in Drupal using Drush ?

1. First, follow the user interface steps provided if necessary to edit the site maintenance message.

2. Then, run the drush sset system.maintenance_mode 1 drush cr command to enable maintenance mode and clear cache.

3. Next, run the drush sset system.maintenance_mode 0 drush cr command to disable maintenance mode and clear the cache.

4. Finally, access it in a browser that is not logged in to ensure your site is in maintenance mode or not.

Table of Contents