<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macOS: 11.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "FileProvider",
  "identifier" : "/documentation/FileProvider/NSFileProviderItemDecorating",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "File Provider"
    ],
    "preciseIdentifier" : "c:objc(pl)NSFileProviderItemDecorating"
  },
  "title" : "NSFileProviderItemDecorating"
}
-->

# NSFileProviderItemDecorating

Support for decorating items.

```
protocol NSFileProviderItemDecorating : NSFileProviderItemProtocol
```

## Overview

To adopt this protocol, implement the [`decorations`](/documentation/FileProvider/NSFileProviderItemDecorating/decorations) method for your extension’s [`NSFileProviderItem`](/documentation/FileProvider/NSFileProviderItem-swift.typealias) and return valid identifiers for the desired decorations.

You define decorations in the File Provider extension’s `Info.plist` file by adding the `NSFileProviderDecorations` key to the `NSExtension` dictionary.

```swift
 <key>NSFileProviderDecorations</key>
 <array>
   <dict>
      <key>Identifier</key>
      <string>$(PRODUCT_BUNDLE_IDENTIFIER).hasComments</string>
      <key>BadgeImageType</key>
      <string>com.someone.item.decoration.unreadCommentIcon</string>
      <key>Category</key>
      <string>Badge</string>
      <key>LocalizedTitle</key>
      <dict>
         <key>NSStringFormat</key>
         <string>%@ unread comments</string>
         <key>NSStringFormatValues</key>
         <array>
            <string>item.userInfo.unreadCommentCount</string>
         </array>
      </dict>
   </dict>
 </array>
```

Use the following keys to define the decorations:

- `Identifier`: The decoration’s identifier.
- `BadgeImageType`: A UTI for the item’s badge. To define the badge, create a new UTI that conforms to `com.apple.icon-decoration.badge` and set its icon.
- `Label`: A localizable title for the item. For example, the system displays a title in detail views and VoiceOver.
- `Category`: A string that defines the location of the badge image.

The `Category` value must be one of the following:

- `Badge`: The system displays the badge image on top of the item’s icon. It only displays the first `Badge` image.
- `Sharing`: The system displays the badge image below the icon. It only displays the first `Sharing` image.
- `FolderBadge`: Only available on folder items. The system embosses the image over the folder icon. It only displays the first `FolderBadge` image.

## Topics

### Providing Decorations

[`decorations`](/documentation/FileProvider/NSFileProviderItemDecorating/decorations)

Asks the item for an array of decorations.



---

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)