---
title: Core Spotlight
framework: Core Spotlight
role: collection
role_heading: Framework
platforms: [iOS 9.0+, iPadOS 9.0+, Mac Catalyst 13.0+, macOS 10.13+, visionOS 1.0+]
path: corespotlight
---

# Core Spotlight

Add search capabilities to your app, and index your content so people can find it from Spotlight and Safari.

## Overview

Overview Help people access activities and items within your app by adding details about those items to a Core Spotlight index. The framework provides APIs to add your content to an index, and search for items in that index. You decide what content makes sense to index, but typically you index anything that someone might look for in your app. For example, you might index photos, contacts, the items someone purchased, or data they see in your interface. You can then use Core Spotlight to search for your indexed content and display those results in your app. important: Spotlight File Import extensions don’t provide functionality in macOS. To make custom files available to Spotlight in macOS, create a Spotlight importer plugin. For more information, refer to Spotlight Importer Programming Guide. Your app is responsible for indexing your app’s content and maintaining those indexes. You can index content when your app runs, or provide an app extension to index content when the system requests it. You can index any content your app manages, including files and other content that your app isn’t currently displaying. The indexes you create using Core Spotlight remain on device, and are private to the owner of the device. Devices don’t share indexed data with Apple, or synchronize that data with the person’s other devices. In addition to indexing content, iOS provides additional strategies for making your app’s content searchable: Use the search-related properties of NSUserActivity to add items to the on-device index, with the option to identify the items as eligible for public indexing. Learn more about NSUserActivity in Index Activities and Navigation Points. Use web markup to index content on your web server in Apple’s server-side index, which makes the data available to all iOS users in Spotlight and Safari search results. For more information, see Mark Up Web Content in App Search Programming Guide.

## Topics

### Essentials

- [Core Spotlight updates](updates/corespotlight.md)
- [Adding your app’s content to Spotlight indexes](corespotlight/adding-your-app-s-content-to-spotlight-indexes.md)

### Searchable items

- [CSSearchableItem](corespotlight/cssearchableitem.md)
- [CSSearchableItemAttributeSet](corespotlight/cssearchableitemattributeset.md)
- [CSCustomAttributeKey](corespotlight/cscustomattributekey.md)
- [CSLocalizedString](corespotlight/cslocalizedstring.md)
- [CSPerson](corespotlight/csperson.md)

### Indexes

- [Generating summary and priority data for indexed items](corespotlight/generating-summary-and-priority-data-for-indexed-items.md)
- [CSSearchableIndex](corespotlight/cssearchableindex.md)
- [CSSearchableIndexDelegate](corespotlight/cssearchableindexdelegate.md)
- [CSSearchableIndexDescription](corespotlight/cssearchableindexdescription.md)

### Foundation models support

- [Spotlight search tool](corespotlight/spotlight-search-tool.md)

### Spotlight app extensions

- [Regenerating your app’s indexes on demand](corespotlight/regenerating-your-app-s-indexes-on-demand.md)
- [CSIndexExtensionRequestHandler](corespotlight/csindexextensionrequesthandler.md)
- [CSImportExtension](corespotlight/csimportextension.md)

### Queries

- [Building a search interface for your app](corespotlight/building-a-search-interface-for-your-app.md)
- [Searching for information in your app](corespotlight/searching-for-information-in-your-app.md)
- [CSUserQuery](corespotlight/csuserquery.md)
- [CSUserQueryContext](corespotlight/csuserquerycontext.md)
- [CSSearchQuery](corespotlight/cssearchquery.md)
- [CSSearchQueryContext](corespotlight/cssearchquerycontext.md)
- [CSSuggestion](corespotlight/cssuggestion.md)

### Errors

- [CSIndexError](corespotlight/csindexerror.md)
- [CSSearchQueryError](corespotlight/cssearchqueryerror.md)
- [CSIndex Errors](corespotlight/csindex-errors.md)
- [CSSearchQuery Errors](corespotlight/cssearchquery-errors.md)

### Version

- [CoreSpotlightAPIVersion](corespotlight/corespotlightapiversion.md)

### Structures

- [SearchableItem](corespotlight/searchableitem.md)
