---
title: "Flutter - Use fallback paywalls"
description: "Handle cases when users are offline or Adapty servers aren't available"
---

:::warning
Fallback paywalls are supported by Flutter SDK v2.11 and later.
:::

To maintain a fluid user experience, it is important to set up [fallbacks](/fallback-paywalls) for your flows, [paywalls](paywalls), and [onboardings](onboardings). This precaution extends the application's capabilities in case of partial or complete loss of internet connection.

* **If the application cannot access Adapty servers:**

    It will be able to display a fallback flow or paywall, and access the local onboarding configuration.

* **If the application cannot access the internet:**

    It will be able to display a fallback flow or paywall. Onboardings include remote content and require an internet connection to function.

:::important
Before you follow the steps in this guide, [download](/local-fallback-paywalls) the fallback configuration files from Adapty.
:::

## Configuration

1. Add the fallback configuration files to the app’s `assets` directory at the project root. 
2. Call the `.setFallback` method **before** you fetch the target paywall or onboarding.

```dart showLineNumbers title="Flutter"

final assetId = Platform.isIOS ? 'assets/ios_fallback.json' : 'assets/android_fallback.json';

try {
  await Adapty().setFallback(assetId);
} on AdaptyError catch (adaptyError) {
  // handle the error
} catch (e) {
}
```

Parameters:

| Parameter      | Description                                                                                                                                                          |
| :------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **assetId**    | Path to the fallback configuration file. |

:::tip

Want to see a real-world example of how Adapty SDK is integrated into a mobile app? Check out our [sample apps](sample-apps), which demonstrate the full setup, including displaying paywalls, making purchases, and other basic functionality.

:::