<!--
{
  "availability" : [
    "iOS: 9.0.0 -",
    "iPadOS: 9.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.11.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreSpotlight",
  "identifier" : "/documentation/CoreSpotlight/CSIndexError/Code",
  "metadataVersion" : "0.1.0",
  "role" : "Enumeration",
  "symbol" : {
    "kind" : "Enumeration",
    "modules" : [
      "Core Spotlight"
    ],
    "preciseIdentifier" : "c:@E@CSIndexErrorCode"
  },
  "title" : "CSIndexError.Code"
}
-->

# CSIndexError.Code

Error codes that describe indexing-specific errors.

```
enum Code
```

## Topics

### Getting the indexing error codes

[`CSIndexErrorCodeIndexUnavailableError`](/documentation/CoreSpotlight/CSIndexError/Code/indexUnavailableError)

The indexer is unavailable.

[`CSIndexErrorCodeIndexingUnsupported`](/documentation/CoreSpotlight/CSIndexError/Code/indexingUnsupported)

Indexing isn’t supported on the device.

[`CSIndexErrorCodeInvalidClientStateError`](/documentation/CoreSpotlight/CSIndexError/Code/invalidClientStateError)

The provided client state data is invalid.

[`CSIndexErrorCodeInvalidItemError`](/documentation/CoreSpotlight/CSIndexError/Code/invalidItemError)

The searchable item object is invalid.

[`CSIndexErrorCodeMismatchedClientState`](/documentation/CoreSpotlight/CSIndexError/Code/mismatchedClientState)

The provided client state did not match the information in the index.

[`CSIndexErrorCodeQuotaExceeded`](/documentation/CoreSpotlight/CSIndexError/Code/quotaExceeded)

The quota for the bundle has been exceeded.

[`CSIndexErrorCodeRemoteConnectionError`](/documentation/CoreSpotlight/CSIndexError/Code/remoteConnectionError)

An error occurred while communicating with the remote process.

[`CSIndexErrorCodeUnknownError`](/documentation/CoreSpotlight/CSIndexError/Code/unknownError)

An unknown error occurred.

## Relationships

### Conforms To

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Hashable`](/documentation/Swift/Hashable)

[`RawRepresentable`](/documentation/Swift/RawRepresentable)

[`BitwiseCopyable`](/documentation/Swift/BitwiseCopyable)

[`Sendable`](/documentation/Swift/Sendable)

[`Equatable`](/documentation/Swift/Equatable)

---

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)