WordPress at Your Fingertips
filter is not described

enable_maintenance_mode filter-hook . WP 4.6.0

Filters whether to enable maintenance mode.

This filter runs before it can be used by plugins. It is designed for non-web runtimes. If this filter returns true, maintenance mode will be active and the request will end. If false, the request will be allowed to continue processing even if maintenance mode should be active.


add_filter( 'enable_maintenance_mode', 'filter_function_name_6135', 10, 2 );
function filter_function_name_6135( $enable_checks, $upgrading ){
	// filter...

	return $enable_checks;
Whether to enable maintenance mode.
Default: true
The timestamp set in the .maintenance file.


Since 4.6.0 Introduced.

Where the hook is called

wp-includes/load.php 329
if ( ! apply_filters( 'enable_maintenance_mode', true, $upgrading ) ) {

Where in WP core the hook is used WordPress

Usage not found.