{"id":110846,"date":"2018-02-03T10:27:51","date_gmt":"2018-02-03T10:27:51","guid":{"rendered":"https:\/\/webkul.com\/blog\/?p=110846"},"modified":"2024-03-18T09:46:12","modified_gmt":"2024-03-18T09:46:12","slug":"maintenance-mode-magento2","status":"publish","type":"post","link":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/","title":{"rendered":"Maintenance mode in Magento2"},"content":{"rendered":"\n<h3 class=\"wp-block-heading\">What is Maintenance Mode in Magento2<\/h3>\n\n\n\n<p>Maintenance Mode in Magento 2 is a feature that allows administrators to temporarily restrict access to their online store while performing maintenance tasks or making significant changes to the website. When Maintenance Mode is enabled, visitors to the website are presented with a custom maintenance page instead of the regular storefront.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Command to check the Maintenance mode status<\/strong><\/h3>\n\n\n\n<p>We can check whether the maintenance mode is enabled&nbsp;or disabled&nbsp;from the following command in Magento2:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">php bin\/magento maintenance:status<\/pre>\n\n\n\n<p>running the above command output:<br><strong>Status: maintenance mode is not active<\/strong><br><strong>List of exempt IP-addresses: none<\/strong><\/p>\n\n\n\n<p>This shows that maintenance mode is not enabled on the Magento site.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Command to Enable the Maintenance mode<\/h3>\n\n\n\n<p>We can enable the maintenance mode from the following command in Magento2:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\">php bin\/magento maintenance:enable<\/pre>\n\n\n\n<p>running the above command output:<br><strong>Enabled maintenance mode<\/strong><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Command to Enable the Maintenance mode for specific IP addresses<\/h3>\n\n\n\n<p>Activating maintenance mode typically applies restrictions to all IP addresses, displaying the maintenance page to all users attempting to access the website.<br>But there is a situation\/requirement that we want to give access to frontend site to the particular user.<\/p>\n\n\n\n<p>For example, if you need to provide access to the website developer during maintenance, you must include their IP address in the allowed list. This allows anyone from the specified IP addresses to access the site despite maintenance mode being active, while other users will encounter the maintenance page.<\/p>\n\n\n\n<p>We can set as many as IP addresses as we want<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\">php bin\/magento maintenance:enable --ip=192.168.0.107 --ip=192.168.0.108<\/pre>\n\n\n\n<p>the above command output:<br><strong>Enabled maintenance mode<\/strong><br><strong>Set exempt IP-address: 192.168.0.107,192.168.0.108<\/strong><\/p>\n\n\n\n<p>if you again check the status of the Maintenance mode via command line<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\">php bin\/magento maintenance:status<\/pre>\n\n\n\n<p>then the output will be:<br><strong>Status: maintenance mode is active<\/strong><br><strong>List of exempt IP-addresses: 192.168.0.107,192.168.0.108<\/strong><\/p>\n\n\n\n<p>this shows that Maintenance mode is active and only two given IP addresses(<strong>192.168.0.107,192.168.0.108<\/strong>) can access the frontend site and the rest users only see the Maintenance page.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Command to remove all IP addresses from the exempt list<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\">php bin\/magento maientenace:enable --ip=none<\/pre>\n\n\n\n<p>the above command output is:<br><strong>Enabled maintenance mode<\/strong><br><strong>Set exempt IP-addresses: none<\/strong><\/p>\n\n\n\n<p>means no user from any IP address is allowed to access the frontend of the website.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Command to disable the Maintenance mode<\/strong><\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\">php bin\/magento maintenance:disable<\/pre>\n\n\n\n<p>the above command output is:<\/p>\n\n\n\n<p><strong>Disabled maintenance mode<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>What is Maintenance Mode in Magento2 Maintenance Mode in Magento 2 is a feature that allows administrators to temporarily restrict access to their online store while performing maintenance tasks or making significant changes to the website. When Maintenance Mode is enabled, visitors to the website are presented with a custom maintenance page instead of the <a href=\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\">[&#8230;]<\/a><\/p>\n","protected":false},"author":169,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[302],"tags":[],"class_list":["post-110846","post","type-post","status-publish","format-standard","hentry","category-magento2"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Maintenance mode in Magento2 - Webkul Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Maintenance mode in Magento2 - Webkul Blog\" \/>\n<meta property=\"og:description\" content=\"What is Maintenance Mode in Magento2 Maintenance Mode in Magento 2 is a feature that allows administrators to temporarily restrict access to their online store while performing maintenance tasks or making significant changes to the website. When Maintenance Mode is enabled, visitors to the website are presented with a custom maintenance page instead of the [...]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\" \/>\n<meta property=\"og:site_name\" content=\"Webkul Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/webkul\/\" \/>\n<meta property=\"article:published_time\" content=\"2018-02-03T10:27:51+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-03-18T09:46:12+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-og.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"630\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Ramakant Pandey\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@webkul\" \/>\n<meta name=\"twitter:site\" content=\"@webkul\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Ramakant Pandey\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\"},\"author\":{\"name\":\"Ramakant Pandey\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/person\/e900dd4548d308477830b501e60214fa\"},\"headline\":\"Maintenance mode in Magento2\",\"datePublished\":\"2018-02-03T10:27:51+00:00\",\"dateModified\":\"2024-03-18T09:46:12+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\"},\"wordCount\":367,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/webkul.com\/blog\/#organization\"},\"articleSection\":[\"Magento2\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\",\"url\":\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\",\"name\":\"Maintenance mode in Magento2 - Webkul Blog\",\"isPartOf\":{\"@id\":\"https:\/\/webkul.com\/blog\/#website\"},\"datePublished\":\"2018-02-03T10:27:51+00:00\",\"dateModified\":\"2024-03-18T09:46:12+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/webkul.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Maintenance mode in Magento2\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/webkul.com\/blog\/#website\",\"url\":\"https:\/\/webkul.com\/blog\/\",\"name\":\"Webkul Blog\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/webkul.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/webkul.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/webkul.com\/blog\/#organization\",\"name\":\"WebKul Software Private Limited\",\"url\":\"https:\/\/webkul.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png\",\"contentUrl\":\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png\",\"width\":380,\"height\":380,\"caption\":\"WebKul Software Private Limited\"},\"image\":{\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/webkul\/\",\"https:\/\/x.com\/webkul\",\"https:\/\/www.instagram.com\/webkul\/\",\"https:\/\/www.linkedin.com\/company\/webkul\",\"https:\/\/www.youtube.com\/user\/webkul\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/person\/e900dd4548d308477830b501e60214fa\",\"name\":\"Ramakant Pandey\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/1ea0042b92622eca16d3d8512f51f69bb43d023e0a40fa07bfc6fc5ca068f56c?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/1ea0042b92622eca16d3d8512f51f69bb43d023e0a40fa07bfc6fc5ca068f56c?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g\",\"caption\":\"Ramakant Pandey\"},\"url\":\"https:\/\/webkul.com\/blog\/author\/ramakant-pandey019\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Maintenance mode in Magento2 - Webkul Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/","og_locale":"en_US","og_type":"article","og_title":"Maintenance mode in Magento2 - Webkul Blog","og_description":"What is Maintenance Mode in Magento2 Maintenance Mode in Magento 2 is a feature that allows administrators to temporarily restrict access to their online store while performing maintenance tasks or making significant changes to the website. When Maintenance Mode is enabled, visitors to the website are presented with a custom maintenance page instead of the [...]","og_url":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/","og_site_name":"Webkul Blog","article_publisher":"https:\/\/www.facebook.com\/webkul\/","article_published_time":"2018-02-03T10:27:51+00:00","article_modified_time":"2024-03-18T09:46:12+00:00","og_image":[{"width":1200,"height":630,"url":"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-og.png","type":"image\/png"}],"author":"Ramakant Pandey","twitter_card":"summary_large_image","twitter_creator":"@webkul","twitter_site":"@webkul","twitter_misc":{"Written by":"Ramakant Pandey","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#article","isPartOf":{"@id":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/"},"author":{"name":"Ramakant Pandey","@id":"https:\/\/webkul.com\/blog\/#\/schema\/person\/e900dd4548d308477830b501e60214fa"},"headline":"Maintenance mode in Magento2","datePublished":"2018-02-03T10:27:51+00:00","dateModified":"2024-03-18T09:46:12+00:00","mainEntityOfPage":{"@id":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/"},"wordCount":367,"commentCount":0,"publisher":{"@id":"https:\/\/webkul.com\/blog\/#organization"},"articleSection":["Magento2"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/","url":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/","name":"Maintenance mode in Magento2 - Webkul Blog","isPartOf":{"@id":"https:\/\/webkul.com\/blog\/#website"},"datePublished":"2018-02-03T10:27:51+00:00","dateModified":"2024-03-18T09:46:12+00:00","breadcrumb":{"@id":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/webkul.com\/blog\/maintenance-mode-magento2\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/webkul.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Maintenance mode in Magento2"}]},{"@type":"WebSite","@id":"https:\/\/webkul.com\/blog\/#website","url":"https:\/\/webkul.com\/blog\/","name":"Webkul Blog","description":"","publisher":{"@id":"https:\/\/webkul.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/webkul.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/webkul.com\/blog\/#organization","name":"WebKul Software Private Limited","url":"https:\/\/webkul.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png","contentUrl":"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png","width":380,"height":380,"caption":"WebKul Software Private Limited"},"image":{"@id":"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/webkul\/","https:\/\/x.com\/webkul","https:\/\/www.instagram.com\/webkul\/","https:\/\/www.linkedin.com\/company\/webkul","https:\/\/www.youtube.com\/user\/webkul\/"]},{"@type":"Person","@id":"https:\/\/webkul.com\/blog\/#\/schema\/person\/e900dd4548d308477830b501e60214fa","name":"Ramakant Pandey","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/webkul.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/1ea0042b92622eca16d3d8512f51f69bb43d023e0a40fa07bfc6fc5ca068f56c?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1ea0042b92622eca16d3d8512f51f69bb43d023e0a40fa07bfc6fc5ca068f56c?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g","caption":"Ramakant Pandey"},"url":"https:\/\/webkul.com\/blog\/author\/ramakant-pandey019\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts\/110846","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/users\/169"}],"replies":[{"embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/comments?post=110846"}],"version-history":[{"count":13,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts\/110846\/revisions"}],"predecessor-version":[{"id":428005,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts\/110846\/revisions\/428005"}],"wp:attachment":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/media?parent=110846"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/categories?post=110846"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/tags?post=110846"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}