---
title: didEnterBackground
framework: foundation
role: symbol
role_heading: Type Property
path: foundation/notificationcenter/messageidentifier/didenterbackground-5gdtk
---

# didEnterBackground

An identifier for a message about a host app beginning to run in the background.

## Declaration

```swift
static var didEnterBackground: NotificationCenter.BaseMessageIdentifier<NSExtensionContext.DidEnterBackgroundMessage> { get }
```

## Discussion

Discussion Use this identifier with NotificationCenter’s addObserver(of:for:using:) or messages(of:for:bufferSize:) methods to observe messages of type NSExtensionContext.DidEnterBackgroundMessage.

## See Also

### Identifying extension messages

- [didBecomeActive](foundation/notificationcenter/messageidentifier/didbecomeactive-79dvm.md)
- [willResignActive](foundation/notificationcenter/messageidentifier/willresignactive-9z4xc.md)
- [willEnterForeground](foundation/notificationcenter/messageidentifier/willenterforeground-p1og.md)
