<!--
{
  "availability" : [

  ],
  "documentType" : "symbol",
  "framework" : "CloudKitJS",
  "identifier" : "/documentation/CloudKitJS/CloudKit.CKError",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "CloudKit JS"
    ],
    "preciseIdentifier" : "cl/CloudKit.CKError"
  },
  "title" : "CloudKit.CKError"
}
-->

# CloudKit.CKError

A [`CloudKit.CKError`](/documentation/CloudKitJS/CloudKit.CKError) object encapsulates an error that may occur when you use CloudKit JS. This includes CloudKit server errors and local errors.

```
interface CloudKit.CKError
```

## Topics

### Handling Errors

[`readonly attribute Boolean isError;`](/documentation/CloudKitJS/CloudKit.CKError/isError)

A Boolean value indicating whether this is an error object.

[`readonly attribute Boolean isCKError;`](/documentation/CloudKitJS/CloudKit.CKError/isCKError)

A Boolean value indicating whether this is a CloudKit error object.

[`readonly attribute String ckErrorCode;`](/documentation/CloudKitJS/CloudKit.CKError/ckErrorCode)

The error code for this error.

[`readonly attribute Boolean isServerError;`](/documentation/CloudKitJS/CloudKit.CKError/isServerError)

A Boolean value indicating whether a server error occurred.

[`readonly attribute String serverErrorCode;`](/documentation/CloudKitJS/CloudKit.CKError/serverErrorCode)

The error code generated by the server.

[`readonly attribute String reason;`](/documentation/CloudKitJS/CloudKit.CKError/reason)

A description of the error that occurred.

[`readonly attribute Number retryAfter;`](/documentation/CloudKitJS/CloudKit.CKError/retryAfter)

The suggested time to wait before trying this operation again.

[`readonly attribute String uuid;`](/documentation/CloudKitJS/CloudKit.CKError/uuid)

A unique identifier for this error.

[`readonly attribute String redirectURL;`](/documentation/CloudKitJS/CloudKit.CKError/redirectURL)

A redirect URL for the user to securely sign in with the user’s Apple ID.

### Identifying the Operation

[`readonly attribute String recordName;`](/documentation/CloudKitJS/CloudKit.CKError/recordName)

The name of the record that the operation failed on.

[`readonly attribute String subscriptionID;`](/documentation/CloudKitJS/CloudKit.CKError/subscriptionID)

A string that is a unique identifier for the subscription where the error occurred.

[`readonly attribute CloudKit.ZoneID zoneID;`](/documentation/CloudKitJS/CloudKit.CKError/zoneID)

The record zone in the database where the error occurred.

### Constants

[Errors](/documentation/CloudKitJS/errors)

The errors that may occur when posting requests.



---

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)