# Onboard invited users from their first screen

> Carry an invite link through the install so the first launch greets the invited person by inviter and skips the blank sign-up screen.

Page: https://warplink.app/use-cases/invite-friends-onboarding

An invited person should open your app and see who invited them, not a blank sign-up. We carry the invite link through the install, so the first launch knows which link brought the person and sends the destination you set on it. Your onboarding then greets them and fills in the context you chose.

## How it works

1. **Create one invite link per inviter.** Create a link whose destination is a path in your app that names the inviter, such as https://example.com/invite/ana. Turn on Referral link, so iPhone can hand the invitation over exactly.
2. **Choose the first-run screen.** Decide what the invited person sees first: a welcome by the inviter's name, a pre-filled team or board, or a trial that matches the invite. Keep a generic welcome for people who arrive without one.
3. **Read the link at first launch.** Android receives the invitation from the Play install referrer. On iPhone, show WarpLinkPasteButton on the welcome screen. React Native and Flutter call redeemInvitation with the pasted text.
4. **Route on the destination.** The SDK returns the destination you set on the link. Read the inviter from it, look up the display name in your own backend, and open the welcome screen before sign-up.
5. **Offer a skip.** Skipping the paste step is fine: onboarding continues with the generic welcome, and the paste stays available later in the flow, so a late decision still applies the invitation.
6. **Watch which invites bring installs.** Each invite link has its own clicks, unique clicks and installs, so you can see which inviters bring people into the app and where those people come from.

## Greet the invited person

### iOS (Swift)

```swift
import WarpLink

WarpLinkPasteButton { result in
    guard case .success(let link) = result, let link else { return showGenericWelcome() }
    // The destination you set on the invite link, for example https://example.com/invite/ana
    showWelcome(invitedBy: link.destination)
}
```

### Android (Kotlin)

```kotlin
WarpLink.configure(
    context = this,
    // SDK key from Keys > SDK
    apiKey = "wl_live_yoursdkkeyhere000000000000000000",
    options = WarpLinkOptions(onLink = { result ->
        result.onSuccess { deepLink ->
            // The destination you set on the invite link, for example https://example.com/invite/ana
            showWelcome(invitedBy = deepLink.destination)
        }
    })
)
```

### React Native

```typescript
import { WarpLink } from '@warplink/react-native'

// The person pastes the invitation into a field on your onboarding screen.
const link = await WarpLink.redeemInvitation(pastedText)
if (link) {
  // The destination you set on the invite link, for example https://example.com/invite/ana
  showWelcome({ invitedBy: link.destination })
} else {
  showGenericWelcome()
}
```

### Flutter

```dart
import 'package:warplink_flutter/warplink_flutter.dart';

// The person pastes the invitation into a field on your onboarding screen.
final link = await WarpLink.redeemInvitation(pastedText);
if (link != null) {
  // The destination you set on the invite link, for example https://example.com/invite/ana
  showWelcome(invitedBy: link.destination);
} else {
  showGenericWelcome();
}
```

## What you get

- **Linking.** A destination you control on each invite link, an invitation page for iPhone visitors without the app, and link-level fallback URLs for visitors on other devices.
- **Attribution.** The install is tied to the link that brought it, so the first launch reads the right invite. A handed-over invitation is an exact match, and an iPhone estimate uses probabilistic matching.
- **Analytics.** Clicks, unique clicks and installs per invite link, with device and country breakdowns.

## Questions

### How is this different from a referral program?

A referral program credits the inviter. Onboarding shapes the invited person's first screen. The same invite link can do both: it greets the friend in your app and, with a claim after sign-up, credits the person who shared it.

### What does an invited iPhone user see without the app?

An invitation page, then the App Store. After the install, the first launch offers a paste control that hands the invitation to the app.

### What if the person skips the paste or has no invite?

Onboarding continues with your generic welcome. The paste control stays available, so the person can apply the invitation later.

### Can I show the inviter's name?

Yes. Put the inviter in the link's destination, such as /invite/ana, and read it from the destination the SDK returns. Your backend supplies the display name.

### Does this work on Android?

Yes. The Play install referrer carries the invitation through the install, and the SDK delivers the link at first launch with no screen of yours.

### Which SDK version do I need?

Use SDK 1.2.0 or later on iOS, Android, React Native or Flutter.

## Related

- [Referrals guide](https://warplink.app/docs/guides/referrals)
- [Invitations API reference](https://warplink.app/docs/api/invitations)
- [iOS attribution reference](https://warplink.app/docs/sdks/ios/attribution)
- [Deferred deep linking](https://warplink.app/deferred-deep-linking)
- [App referral programs](https://warplink.app/use-cases/app-referral-programs)
