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

# Installation

> Add the Swift SDK to your iOS project and configure ATT + SKAdNetwork.

<Note>
  You'll need a [publisher account](/publishers#getting-started-is-easy) to obtain your `publisherToken` and placement codes.
</Note>

## 1. Add the SDK

<Tabs>
  <Tab title="Swift Package Manager">
    Add the SDK as a package dependency:

    ```swift theme={null}
    dependencies: [
        .package(url: "https://github.com/kontextso/sdk-swift", .upToNextMajor(from: "4.0.0")) // pulls the latest 4.x
    ]
    ```

    Then add the `KontextSwiftSDK` product to your target.
  </Tab>

  <Tab title="CocoaPods">
    Add to your `Podfile`:

    ```ruby theme={null}
    pod 'KontextSwiftSDK', '~> 4.0' # pulls the latest 4.x
    ```

    Then run `pod install`.
  </Tab>
</Tabs>

## 2. Set up IDFA (App Tracking Transparency)

Add `NSUserTrackingUsageDescription` to `Info.plist`. The SDK auto-prompts for ATT the first time a session is created and reads IDFA + IDFV from there.

See [IFA & ATT](/guides/ifa) for the full setup — required `Info.plist` key, prompt-timing gotchas, and how to manage the prompt yourself.

## 3. Set up SKAdNetwork

Add the SKAdNetwork identifiers we provide during onboarding to `Info.plist`. The SDK reads them at startup and forwards them on every `/init`.

See [SKAdNetwork](/guides/skadnetwork) for the full guide.
