# Boost Push Opt-In with In-App Automation

Push notifications are key when it comes to communicating with your app users. In order to send your users notifications, they have to opt in. With iOS devices you only get one chance to ask your users to opt-in, which means it is critical to make sure you ask your users at the right time and in a thoughtful way.

Airship’s [In-App Automation](https://www.airship.com/docs/reference/glossary/#iaa) makes it easy to create a soft prompt for a user’s permission, giving you the opportunity to maximize your opt-in rates, no development effort required. Here’s how to get started.

*For more information about each step mentioned here, see: [Create an In-App Automation](https://www.airship.com/docs/guides/messaging/in-app-experiences/in-app-automation/create/).*

## Create an In-App Automation

Our goal is to create a custom in-app message to evaluate whether or not the user is ready to opt in to our push messaging.

To get started, access the In-App Automation composer:

1. Select **Create** in the sidebar.
1. Next to **Build from scratch**, select **View all**.
1. Select **In-App Automation**.

## Pick the right style and layout

When choosing the style of the message, we advise to use modal or fullscreen so you have some room to explain the reasons for your request.

![Selecting a message style for the opt-in prompt](https://www.airship.com/docs/images/composer-style_hu_8ed3d5a8557c5d0a.webp)

*Selecting a message style for the opt-in prompt*

The layout is really up to you, but it’s known that adding an image will make your message more engaging. For this example we are choosing the *Media | Header | Body* layout for a fullscreen message.

   > **Note:** If your account includes Personalization features, you will instead select a layout in the Content step.


## Customize the In-App Automation

The next step, *Settings*, is where you give your message a name and choose among options Airship proposes, for example:

* Set a message priority to make sure users see your opt-in request before other messages.
* Enter a campaign category to make your reporting easier.
* Enable localization so that you can address your global audience in different languages.

In this tutorial, we will not add any options and call our message `Push opt-in request`.

It’s important to choose the right audience for this message. In the *Audience* step, our recommendation is to target by *Push opt-in status* and choose *Opted-out of push notifications*, which will target users who are not yet opted in. 

Now you have to set up the content of your in-app message. It should give the user context for what types of notifications they can expect, or what the benefit is to them for opting in (e.g., don't miss updates about your favorite show, or important account transaction notifications, etc.). 
Also, it should be designed in a way that if a user says No, no worries, you can still try again later. Create two buttons, with labels `Maybe later` and `Yes please`.

> **Note:** If your account includes Personalization features, first click **Classic** and select a layout, then proceed with configuring the content.


![Configuring the opt-in prompt content and layout](https://www.airship.com/docs/images/use-cases/iaa-push-opt-in/image5_hu_c724199afd6f627b.webp)

*Configuring the opt-in prompt content and layout*

## Add a call to action to opt-In

In the *Actions* step, you will assign an action for each button. Airship provides an easy way to trigger the system prompt for push notifications opt-in — select *Push Opt-in* for the `Yes please` button.

Also note that we added a tag when the `Maybe later` button is tapped, in case you want to retarget those users.  

![Configuring button actions for the opt-in prompt](https://www.airship.com/docs/images/use-cases/iaa-push-opt-in/image6_hu_924218acc4af899c.webp)

*Configuring button actions for the opt-in prompt*

## Triggering the prompt

Finally, in the *Behavior* step, you need to decide what will trigger your in-app message. A simple and our-of-the-box way to do it is to display the message after the app is opened a certain number of times: select the *App Open* trigger and enter a number.

![Setting an App Open trigger for the opt-in prompt](https://www.airship.com/docs/images/use-cases/iaa-push-opt-in/image2_hu_a5d39fa0f907b00b.webp)

*Setting an App Open trigger for the opt-in prompt*

Another smart way is to track specific custom events that would be defined in your app. Emphasizing exactly how push notifications will contribute and enhance the user experience based on their unique actions is more likely to sway your users to opt in. Depending on your industry, it can vary, but here are few examples: Viewed item, Articles read, Number of sessions, etc. Select the *Custom Event* trigger, specify an event, then enter the number of times the event must occur before the message will display. You can specify multiple events.

![Setting a Custom Event trigger for the opt-in prompt](https://www.airship.com/docs/images/use-cases/iaa-push-opt-in/image3_hu_315ca2a3c8d0a718.webp)

*Setting a Custom Event trigger for the opt-in prompt*

## Review and make active

Once setup is complete, the in-app automation is ready and can be made active. Click **Finish**. 🎉
