<!--
{
  "documentType" : "article",
  "framework" : "FileProvider",
  "identifier" : "/documentation/FileProvider/replicated-file-provider-extension",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Replicated File Provider extension"
}
-->

# Replicated File Provider extension

Build a File Provider extension that syncs the local copies of your files with your remote storage.

## Discussion

When creating a replicated File Provider extension, the system takes responsibility for managing and storing the local copies of your documents and folders. Your extension syncs data between the local copy and the remote storage, providing the local system with the metadata and contents of the items in your remote storage. It also alerts the system to any remote changes to those items and uploads any local changes back to the remote storage. For more information, see [Synchronizing the File Provider Extension](/documentation/FileProvider/synchronizing-the-file-provider-extension).

At a minimum, the File Provider extension needs to perform the following:

- Adopt both the [`NSFileProviderReplicatedExtension`](/documentation/FileProvider/NSFileProviderReplicatedExtension) and the [`NSFileProviderEnumerating`](/documentation/FileProvider/NSFileProviderEnumerating) protocols. You can add additional features by implementing the other protocols listed in the File Provider protocols listed below.
- Implement an object that adopts the [`NSFileProviderEnumerator`](/documentation/FileProvider/NSFileProviderEnumerator) protocol to enumerate the items from your remote storage when the system calls your [`enumerator(for:request:)`](/documentation/FileProvider/NSFileProviderEnumerating/enumerator(for:request:)) method.
- Implement a class that adopts the [`NSFileProviderItemVersion`](/documentation/FileProvider/NSFileProviderItemVersion) protocol to represent the items (directories and files) enumerated by your file provider.

> Note:
> The system uses two different enumerators. The first lets the system enumerate items from your remote storage. The second lets your app enumerate the items stored locally by the system. You must implement the first enumerator, returning it when the system calls your ``doc://com.apple.fileprovider/documentation/FileProvider/NSFileProviderEnumerating/enumerator(for:request:)`` method. The system provides the second enumerator when you call methods like the ``doc://com.apple.fileprovider/documentation/FileProvider/NSFileProviderManager`` class’s ``doc://com.apple.fileprovider/documentation/FileProvider/NSFileProviderManager/enumeratorForMaterializedItems()`` method.

Your File Provider extension can add custom actions to the file browser’s context menu using the <doc://com.apple.documentation/documentation/FileProviderUI> framework. You can also define custom services to communicate with the host app using <doc://com.apple.documentation/documentation/Foundation/NSFileProviderService>. Use these interfaces to add features that aren’t provided by the base API.

## Topics

### Essentials

[Synchronizing the File Provider Extension](/documentation/FileProvider/synchronizing-the-file-provider-extension)

Keep the local and remote copies of your File Provider extension’s content in sync.

[Synchronizing files using file provider extensions](/documentation/FileProvider/synchronizing-files-using-file-provider-extensions)

Make remote files available in macOS and iOS, and synchronize their states by using file provider extensions.

[Setting the Finder Sidebar Icon](/documentation/FileProvider/setting-the-finder-sidebar-icon)

Specify a standard or custom symbol as a sidebar icon.

### File Provider protocols

[`NSFileProviderReplicatedExtension`](/documentation/FileProvider/NSFileProviderReplicatedExtension)

A File Provider extension in which the system replicates the contents on disk.

[`NSFileProviderEnumerating`](/documentation/FileProvider/NSFileProviderEnumerating)

Support for enumerating the file provider’s contents.

[`NSFileProviderIncrementalContentFetching`](/documentation/FileProvider/NSFileProviderIncrementalContentFetching)

Support for fetching changes to the item’s content.

[`NSFileProviderPartialContentFetching`](/documentation/FileProvider/NSFileProviderPartialContentFetching)

Support for fetching part of a file’s content.

[`NSFileProviderServicing`](/documentation/FileProvider/NSFileProviderServicing)

Support for providing a custom service source.

[`NSFileProviderCustomAction`](/documentation/FileProvider/NSFileProviderCustomAction)

Support for custom actions.

[`NSFileProviderExtensionActionIdentifier`](/documentation/FileProvider/NSFileProviderExtensionActionIdentifier)

An identifier for custom actions.

[`NSFileProviderThumbnailing`](/documentation/FileProvider/NSFileProviderThumbnailing)

Support for item thumbnails.

[`NSFileProviderPendingSetEnumerator`](/documentation/FileProvider/NSFileProviderPendingSetEnumerator)

A protocol for enumerating pending items.

### Items and metadata

[`NSFileProviderItemFields`](/documentation/FileProvider/NSFileProviderItemFields)

Fields that specify which of the item’s properties have changed.

[`NSFileProviderItemVersion`](/documentation/FileProvider/NSFileProviderItemVersion)

The version of the item’s content and its metadata.

[`NSFileProviderRequest`](/documentation/FileProvider/NSFileProviderRequest)

An object that provides information about the application requesting data from the File Provider extension.

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

Support for decorating items.

[`NSFileProviderItemDecorationIdentifier`](/documentation/FileProvider/NSFileProviderItemDecorationIdentifier)

A decoration identifier defined in the File Provider extension’s information property list.

### Domains

[`NSFileProviderDomainVersion`](/documentation/FileProvider/NSFileProviderDomainVersion)

An opaque object that identifies a specific version of a domain.

[`NSFileProviderDomainState`](/documentation/FileProvider/NSFileProviderDomainState)

An object that contains global state data about the domain.

### Testing protocols

[`NSFileProviderTestingChildrenEnumeration`](/documentation/FileProvider/NSFileProviderTestingChildrenEnumeration)

An operation that lists a directory’s content.

[`NSFileProviderTestingCollisionResolution`](/documentation/FileProvider/NSFileProviderTestingCollisionResolution)

An operation that resolves a collision by renaming the new item.

[`NSFileProviderTestingContentFetch`](/documentation/FileProvider/NSFileProviderTestingContentFetch)

An operation that fetches an item’s content.

[`NSFileProviderTestingCreation`](/documentation/FileProvider/NSFileProviderTestingCreation)

An operation that syncs the creation of the source item to the target location.

[`NSFileProviderTestingDeletion`](/documentation/FileProvider/NSFileProviderTestingDeletion)

An operation that syncs the deletion of the source item to the target location.

[`NSFileProviderTestingIngestion`](/documentation/FileProvider/NSFileProviderTestingIngestion)

An operation that alerts the system to either local or remote storage changes.

[`NSFileProviderTestingLookup`](/documentation/FileProvider/NSFileProviderTestingLookup)

An operation that looks up an item.

[`NSFileProviderTestingModification`](/documentation/FileProvider/NSFileProviderTestingModification)

An operation that syncs the modification of the source item to the target location.

[`NSFileProviderTestingOperation`](/documentation/FileProvider/NSFileProviderTestingOperation)

An operation that the system can schedule.

[`NSFileProviderUserInteractionSuppressing`](/documentation/FileProvider/NSFileProviderUserInteractionSuppressing)

Support for suppressing user-interaction alerts.

[`NSFileProviderTestingOperationSide`](/documentation/FileProvider/NSFileProviderTestingOperationSide)

The location where the operation takes place.

[`NSFileProviderTestingOperationType`](/documentation/FileProvider/NSFileProviderTestingOperationType)

The action that an operation performs.

  <doc://com.apple.documentation/documentation/BundleResources/Entitlements/com.apple.developer.fileprovider.testing-mode>

### Information property list keys

  <doc://com.apple.documentation/documentation/BundleResources/Information-Property-List/NSDownloadsUbiquitousContents>

  <doc://com.apple.documentation/documentation/BundleResources/Entitlements/com.apple.developer.fileprovider.testing-mode>

  <doc://com.apple.documentation/documentation/BundleResources/Information-Property-List/CFBundleIcons/CFBundlePrimaryIcon/CFBundleSymbolName>



---

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)