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

# isActive()

> Asynchronously check if an entitlement is currently active with automatic smart refresh

Asynchronously queries whether a given entitlement type is currently active for the user. Use this to gate features or show conditional UI based on active entitlements. This method automatically performs a smart refresh to guarantee fresh entitlement data before returning the result.

## Signature

```swift theme={null}
public func isActive(
  _ type: Entitlement,
  in scope: EntitlementScope = .all
) async -> Bool
```

## Parameters

| Name    | Type                                    | Description                                                                                                       |
| ------- | --------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| `type`  | [Entitlement](./entitlements)           | The entitlement type                                                                                              |
| `scope` | [EntitlementScope](./entitlement-scope) | The scope to check (`.all` includes provisional grants; `.verified` refreshes against the backend's verified set) |

## Returns

Returns `true` if the specified entitlement is currently active for the user, `false` otherwise.

## Usage

```swift theme={null}
Task {
  let hasTrial = await Encore.shared.isActive(.freeTrial(), in: .all)
  
  if hasTrial {
    // User has an active free trial
    showPremiumFeatures()
  } else {
    // User doesn't have a free trial
    showUpgradePrompt()
  }
}
```

<Tip>
  For reactive, real-time entitlement tracking in Combine-based apps, use [`isActivePublisher()`](./is-active-publisher) instead.
</Tip>
