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

# Variables and state

> Manage variables and state in iOS

## Variables and state

Use variables to personalize flows on iOS. Values are synced from the app to RampKit and referenced in the builder.

Set user attributes at runtime:

```swift theme={null}
RampKit.setUserAttributes([
  "plan": "pro",
  "country": "US",
  "daysSinceInstall": 3
])
```

Read variables inside your app:

```swift theme={null}
let headline = RampKit.variable("paywallHeadline") ?? "Upgrade"
let cta = RampKit.variable("primaryCta") ?? "Continue"
```
