# Maintenance Windows

Temporarily disable a service, along with its integrations and incidents

Maintenance windows temporarily disable a service, including all of its integrations, for a set period of time. While a service is in a maintenance window, its integrations are disabled and no new incidents will trigger. When a maintenance window ends, incidents can trigger on the service again.

Existing open incidents will not resolve when a maintenance window begins; they will remain open and continue to notify users as expected unless they are manually resolved.

Additionally, while a service is in a maintenance window, incidents cannot be resolved through the [Events API](/developer/events-api-v2-overview).

> **Required User Permissions:** The following roles can create, edit and delete maintenance windows: 
>
> - User
> - Manager base roles and Team roles
>   - Manager Team roles can only manage maintenance windows associated with their Team.
> - Admin/Global Admin
> - Account Owner
>
> If you're not sure what role you have, or if you need your permissions adjusted, visit our sections [Check Your User Role](/account-admin/user-roles#check-your-user-role) or [Edit User Roles](/account-admin/manage-users#edit-user-roles).

## Create a Maintenance Window

You can schedule a maintenance window to begin immediately or at a later date and time.

### Web App

1. Navigate to **Services**  →  **Service Directory** and select a service you’d like to put into maintenance mode.
2. On the service’s detail page, select **More**  →  **Schedule Maintenance** in the top right.
3. In the **Create Maintenance Window** modal, your service will already be populated under **Services Affected** and you may _optionally_ select other services from the dropdown.
4. _Optional_: Enter a **Description** to give team members context on why the service is going into a maintenance window.
5. Select **Start now and end in** and one of the predefined intervals : **15 minutes, 30 minutes, 60 minutes, 2 hours** or **4 hours**, _or_, to schedule a maintenance window that begins in the future, select **Start at a scheduled time**, select your **Time Zone**, and enter **Start** and **End** dates.
6. Click **Create Maintenance Window**.

### Mobile App

To immediately start a maintenance window in the mobile app:

1. Tap **Services** in the bottom navigation and select your preferred service.
2. Tap  in the top-right corner.
3. Tap **Create Maintenance Window**.
4. _Optional_: In the section **Description**, tap **Add Description**, enter text describing why the maintenance is happening, and tap **Done**.
5. In the section **Schedule Time**, select a duration (i.e., **End in 15 Minutes**, **End in 30 Minutes**, **End in 60 Minutes**, **End in 2 Hours**, **End in 4 Hours**), _or_ to schedule a maintenance window that begins in the future, select the tab **Schedule Later** and enter start and end times that outline when the maintenance window should be active.
   - **Note**: Tap **Time Zone** to set the start and end times in your preferred time zone.
6. Tap **Create Maintenance Window**.
7. In the modal, confirm your selection.

> **Create Maintenance Windows for Multiple Services:** In the mobile app, you can only create a maintenance window for one service at a time. If you'd like to create maintenance windows for multiple services at once, you can do this in the [web app](#web-app).

## View Maintenance Windows

### Web App

You can review which services are in maintenance mode by navigating to **Services**  →  **Service Directory** and selecting the **Maintenance Windows** tab. This page prominently displays all services that are currently in a maintenance window (i.e., **Maintenance Happening Now**).

Below that, the table **All Maintenance Windows** lists all future, ongoing and past maintenance windows. You can restrict results with a search term, service status or Team.

The **Services** tab also indicates which services are in maintenance mode. An icon indicates whether a service in maintenance mode:

-  appears next to a service that is in maintenance mode.
-  appears next to a service that is disabled.

On a service’s detail page,  **Maintenance** appears under the **Status** heading while it is in maintenance mode.

### Mobile App

To view maintenance windows in the mobile app:

1. Tap **Services** in the bottom navigation and select your preferred service.
2. Tap  in the top-right corner.
3. The list view displays all current and future maintenance windows for the selected service.
   - **Note**: Past and terminated maintenance windows are not displayed.

![Mobile app list view showing current and future maintenance windows for a service](/images/kb/25cbbe4e85ec869ee4b2bdbcce88e5c9b6babc4a79fa6e3a0b4ed02c1e328303-maintenance_windows.webp)
*View maintenance windows in the mobile app*

## Update a Maintenance Window

### Web App

To update a current or future maintenance window:

1. Navigate to **Services**  →  **Service Directory** and select the **Maintenance Windows** tab.
2. In the table **All Maintenance Windows**, click **Update** to the right of the maintenance window you’d like to update.
3. In the **Update Maintenance Window** modal, update maintenance window’s details.
4. Click **Save Changes**.

### Mobile App

To update a current or future maintenance window:

1. Tap **Services** in the bottom navigation and select the service with the maintenance window you'd like to update.
2. Tap  in the top-right corner. On the next screen, select the maintenance window you would like to update.
   - _Optional_: In the section **Description**, tap **Add Description**, enter or update the text describing why the maintenance is happening, and tap **Done**.
3. In the section **Schedule Time**, tap the **End** time row and select a new date and time.
4. Tap **Update Maintenance Window**.
5. In the modal, confirm your selection.

![Mobile app screen with an End time row selected and an Update Maintenance Window button](/images/kb/c450762665bd9fde178a44da5eb6a0a7dcdf78b283383022b43adb76378efb4c-update_maintenance_window.webp)
*Update a maintenance window in the mobile app*

> **Update Maintenance Windows for Multiple Services:** Please note that if a maintenance window affects multiple services (e.g., if you created the maintenance window in the [web app](#web-app) and selected multiple services), updating the maintenance window will affect _all_ associated services.

## Delete a Maintenance Window

You can delete any maintenance window that is scheduled to take place in the future. Past maintenance windows are kept for historical records and cannot be deleted. To end an in-progress maintenance window before its scheduled end time, please read [End a Maintenance Window](#end-a-maintenance-window).

1. Navigate to **Services**  →  **Service Directory** and select the **Maintenance Windows** tab.
2. In the table **All Maintenance Windows**, click **Update** to the right of the maintenance window you’d like to delete.
3. In the **Update Maintenance Window** modal, click **Delete**.

## End a Maintenance Window

### Web App

To end a maintenance window early:

1. Go to **Services**  →  **Service Directory** and select the **Maintenance Windows** tab.
2. Under **All Maintenance Windows**, find your desired maintenance window and click **Update** to the right.
3. Click **End Now**.

### Mobile App

You can immediately end any in-progress maintenance window in the mobile app:

1. Tap **Services** in the bottom navigation and select the service with the maintenance window you'd like to end.
2. Tap  in the top-right corner.
3. At the bottom of the screen, tap **End Maintenance Window**.
4. In the confirmation modal, tap **End Maintenance Window**.

> **End Maintenance Windows for Multiple Services:** Please note that if a maintenance window affects multiple services (e.g., if you created the maintenance window in the [web app](#web-app) and selected multiple services), ending the maintenance window will affect _all_ associated services.

## Disable a Service

If you’d like to indefinitely put a service into maintenance mode:

1. In the PagerDuty web app, navigate to **Services**  →  **Service Directory** and select a service to disable.
2. Select **More**  →  **Disable Service**.
3. In the prompt, click **Disable** to confirm your selection.

This service is now disabled and will not trigger incidents until it is [manually enabled](#enable-a-service).

### Enable a Service

To manually enable a disabled service:

1. Navigate to **Services**  →  **Service Directory** and select a [disabled service](#disable-a-service).
2. Select **More**  →  **Enable Service**.

New incidents can now trigger on the service.

## FAQ

**How can I create recurring maintenance windows?**

If you find that you need to regularly put a service into maintenance mode, you can use our REST API to create recurring maintenance windows. The following script can be customized and run in the command line:

- [Python 3 Compatible Script](https://github.com/PagerDuty/public-support-scripts/tree/master/maintenance_windows_bulk_operations) (**Note**: You will need a [REST API key](/account-admin/api-access-keys#rest-api-keys)).

Please note that the script above will not run as is, and requires you to substitute your own email address, v2 REST API key and service ID where indicated. Once the substitutions have been made, the script will allow you to create maintenance windows programmatically.

You may wish to adjust other values in the example, too. For instance, the maintenance duration is set to 30 minutes. Please change this value to adjust the maintenance windows’ duration. The example as written will also create eight maintenance windows, separated from each other by a week's time. Please adjust this value if you’d like a different number of maintenance windows.
