> ## Documentation Index
> Fetch the complete documentation index at: https://algolia.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Improve performance for InstantSearch iOS

> Learn how to optimize your InstantSearch iOS app.

<Info>
  Starting May 1, 2024,
  Apple requires all iOS apps to include a privacy manifest.
  For more information, see [Privacy manifest](/doc/guides/building-search-ui/resources/privacy-manifest/ios/).
</Info>

Algolia is fast by default.
But network speed and bandwidth can vary.
This page lists a few best practices you can implement to adapt to your users' network conditions.

## Add a loading indicator

You can mitigate the impact of a slow network on your search experience by managing user expectations.
One way of letting them know that the network is suboptimal is by displaying a **loading indicator**, which prevents them from becoming frustrated by network delays and blaming your app for lack of responsiveness.

**Use the [`Loading`](/doc/api-reference/widgets/loading/ios) widget to implement this behavior.**

## Optimize build size

To optimize build size, only download the parts of the InstantSearch library that you will use:

### CocoaPods

```ruby Podfile theme={"system"}
pod("InstantSearch", "~> 5.0")
# pod 'InstantSearch/UI' for access to everything
# pod 'InstantSearch/Core' for access to everything except the UI controllers
# pod 'InstantSearch/Client' for access only to the API Client
```

### Carthage

```ruby Cartfile theme={"system"}
github "algolia/instantsearch-ios" ~> 5.0 # for access to everything
# github "algolia/instantsearch-core-swift" ~> 6.0 # for access to everything except the UI widgets
# github "algolia/algoliasearch-client-swift" ~> 7.0 # for access only to the API Client
```

## Queries per second (QPS)

Search operations aren't limited by a fixed "search quota".
Instead, they're limited by your plan's [maximum QPS](https://support.algolia.com/hc/en-us/articles/4406975224721) and
[operations limit](https://support.algolia.com/hc/en-us/articles/18138875086865).

Every keystroke in InstantSearch using the `SearchBox` counts as one operation.
Then, depending on the widgets you add to your search interface,
you may have more operations being counted on each keystroke.
For example, if you have a search interface with a `SearchBox`, a `HierarchicalMenu`, and a `RefinementList`,
then every keystroke triggers one operation.
Upon each user change to a `HierarchicalMenu` or `RefinementList`, a new operation is executed.

For more information, see:

* [`SearchBox`](/doc/api-reference/widgets/search-box/ios)
* [`HierarchicalMenu`](/doc/api-reference/widgets/hierarchical-menu/ios)
* [`RefinementList`](/doc/api-reference/widgets/refinement-list/ios)
