---
title: applicationWillResignActive()
framework: watchkit
role: symbol
role_heading: Instance Method
path: watchkit/wkapplicationdelegate/applicationwillresignactive()
---

# applicationWillResignActive()

Tells the delegate that the system is about to deactivate the watchOS app.

## Declaration

```swift
optional func applicationWillResignActive()
```

## Discussion

Discussion WatchKit calls this method after your app launches and before it exits. Use this method to pause any active tasks. For example, you could use it to stop any active timers. An app in the inactive state should do minimal work while it waits to transition to the active or not running state. If your app has unsaved user data, you can save it here to ensure that it isn’t lost. However, it’s a good idea to save user data at appropriate points throughout the execution of your app, usually in response to user actions. Don’t rely on specific app state transitions to save all of your app’s critical data. note: When creating an app that uses the SwiftUI App protocol to manage your life cycle, use the onChange(of:perform:) modifier and the scenePhase environment value to monitor life cycle changes when possible. For more information, see Building a watchOS app.

## See Also

### Monitoring state changes

- [Working with the watchOS app life cycle](watchkit/working-with-the-watchos-app-life-cycle.md)
- [main()](watchkit/wkapplicationdelegate/main().md)
- [applicationDidFinishLaunching()](watchkit/wkapplicationdelegate/applicationdidfinishlaunching().md)
- [applicationDidBecomeActive()](watchkit/wkapplicationdelegate/applicationdidbecomeactive().md)
- [applicationWillEnterForeground()](watchkit/wkapplicationdelegate/applicationwillenterforeground().md)
- [applicationDidEnterBackground()](watchkit/wkapplicationdelegate/applicationdidenterbackground().md)
- [deviceOrientationDidChange()](watchkit/wkapplicationdelegate/deviceorientationdidchange().md)
