Instance Method


Starts downloading (if necessary) the specified item to the local system.


- (BOOL)startDownloadingUbiquitousItemAtURL:(NSURL *)url error:(NSError * _Nullable *)error;



The URL for the file or directory in the cloud that you want to download.


On input, a pointer to variable for an NSError object. If an error occurs, this pointer is set to an NSError object containing information about the error. You may specify nil to ignore the error information.

Return Value

YES if the download started successfully or was not necessary, otherwise NO. If NO is returned and errorOut is not nil, an NSError object describing the error is returned in that parameter.


If a cloud-based file or directory has not been downloaded yet, calling this method starts the download process. If the item exists locally, calling this method synchronizes the local copy with the version in the cloud.

For a given URL, you can determine if a file is downloaded by getting the value of the NSMetadataUbiquitousItemDownloadingStatusKey key. You can also use related keys to determine the current progress in downloading the file.

See Also

Managing iCloud-Based Items


An opaque token that represents the current user’s iCloud Drive Documents identity.

- URLForUbiquityContainerIdentifier:

Returns the URL for the iCloud container associated with the specified identifier and establishes access to that container.

- isUbiquitousItemAtURL:

Returns a Boolean indicating whether the item is targeted for storage in iCloud.

- setUbiquitous:itemAtURL:destinationURL:error:

Indicates whether the item at the specified URL should be stored in iCloud.

- evictUbiquitousItemAtURL:error:

Removes the local copy of the specified item that’s stored in iCloud.

- URLForPublishingUbiquitousItemAtURL:expirationDate:error:

Returns a URL that can be emailed to users to allow them to download a copy of a flat file item from iCloud.