Send a Push pre-permission message

The Push pre-permission message is a great way to ask for push registrations while giving your users some context about the value of accepting push notifications from your app. 


The Push pre-permission message automatically checks to see if users have enabled push notifications (or if we have already asked for permission) before sending. If the user selects OK, they will receive the iOS-level prompt to register for push. If they select Maybe Later, you can save the iOS prompt for another time.

Create the Push pre-permission message

To send a push pre-permission message, select Create Message from the top right corner of the Messaging center.



Next, select the Push Pre-Permission template from your in-app message templates. 


Now you can add your own text, title, and other content for your message.

Customizing the Push pre-permission message

From the message composer, you can customize the Title, Layout (height and width), Message text, Button text, Background image, and more. You can also select different text and background colors, or add emojis to your text.

Because Push pre-permission messages are not rich html messages, they have less options for customization. But, with some creative use of the background image, you can customize your message layout and add a hero image.

Add a hero image

There are two ways to set up a custom hero image:

1. Use the entire background image as the message.

If you choose to go this route, you'll have to include the message text in your original image design, then delete any text in the message composer. Since the design of the message is totally dependent on your background image, you can customize the layout/look of your message however you like.


Your message may look different in Leanplum's on-screen preview than it will on a device, so always preview your message on a test device.


If the image doesn't look right, adjust the layout of the message itself (height and width settings) or make adjustments to your background image design as needed. 

2. Add a solid-colored buffer below your image where the message text can show.

This option may be better if you plan on re-using the hero image again with different messages, or if your message is using dynamic customization (jinja) or other custom values that would change the text from user to user.

Create a background image with a white or solid-colored section below your hero image — doing so should roughly double the height of your original image. The white block is where the message text from Leanplum will go.


Put your new background image in the push pre-permission template, then type your message in the composer's message field as you normally would. Make sure to test the message on a real device before sending it out to users.

If the message doesn't fit right, adjust the white space or message length as necessary. You may need to add some space above your message in the composer (return/enter) to make sure the message shows up properly. Also, make sure the height and width of the message are large enough for your background image to display fully.



Once again, it's important to preview the message on a developer device to ensure the message looks the way you want it to. Note that with this method, we decided to type our message's title directly in the message body field, so as not to cover the image.

Image sizing tips

The background image ratio should match the ratio you set in the message's layout height and width. If you want the message to be full screen, define the message layout size as 100%/100% and make sure the image size matches the device aspect ratio (in most cases 16x9 or in portrait 9x16).


Was this article helpful?
Have more questions? Submit a request