<!--
{
  "availability" : [
    "iOS: 13.3.0 -",
    "iPadOS: 13.3.0 -",
    "macOS: 11.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "BundleResources",
  "identifier" : "/documentation/BundleResources/Entitlements/com.apple.developer.usernotifications.filtering",
  "metadataVersion" : "0.1.0",
  "role" : "Property List Key",
  "symbol" : {
    "kind" : "Property List Key",
    "modules" : [
      "Bundle Resources"
    ],
    "preciseIdentifier" : "entitlements:Entitlements.com.apple.developer.usernotifications.filtering"
  },
  "title" : "com.apple.developer.usernotifications.filtering"
}
-->

# com.apple.developer.usernotifications.filtering

Enable receiving notifications without displaying the notification to the user.

## Discussion

This entitlement allows a notification service extension to receive remote notifications without displaying the notification to the user. To apply for this entitlement, see [Request Notification Service Entitlement](https://developer.apple.com/contact/request/notification-service).

After you receive permission to use the entitlement, add [`com.apple.developer.usernotifications.filtering`](/documentation/BundleResources/Entitlements/com.apple.developer.usernotifications.filtering) to the entitlements file in the Notification Service Extension target. This allows you to silence push notifications after your extension receives them.

### Silence Push Notifications

To suppress a notification’s alert, create an empty <doc://com.apple.documentation/documentation/UserNotifications/UNNotificationContent> object in your extension’s <doc://com.apple.documentation/documentation/UserNotifications/UNNotificationServiceExtension/didReceive(_:withContentHandler:)> method, and pass it to the content handler. Don’t specify a title, subtitle, body, attachments, or sound for the content.

```swift
override func didReceive(_ request: UNNotificationRequest, withContentHandler contentHandler: @escaping (UNNotificationContent) -> Void) {
    
    // Determine whether you should suppress the notification.
    let suppress = myShouldSuppressNotification(request: request)
    
    if suppress {
        // Don't deliver the notification to the user.
        contentHandler(UNNotificationContent())
        
    } else {
        // Deliver the notification.
        guard let updatedContent = request.content.mutableCopy() as? UNMutableNotificationContent else {
            // This error should never occur.
            fatalError("Unable to create a mutable copy of the content")
        }
        
        // Update the notification's content, such as decrypting the body, here. 
        contentHandler(updatedContent)
    }
}
```

> Note:
> To silence a remote notification, you must set the `apns-push-type` header field to `alert` when you send the notification to the APNS server. Otherwise, the system always displays the notification banner to the user.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)