Variables are filled in for visitors Sleekplan can identify: people signed in to your portal, or visitors you identify through the widget SDK. Anonymous visitors always see the fallback text you provide, so your message reads well for everyone.
The syntax
A variable is a name and a fallback, wrapped in curly braces and separated by a pipe:variableis the detail to insert (see the available variables).fallbackis the text to show when that detail is missing.
Hi {user_first_name|there} 👋 renders as:
- Hi John 👋 for a signed-in visitor named John Doe.
- Hi there 👋 for an anonymous visitor, or one whose name Sleekplan does not have.
The available variables
Four visitor variables are supported:| Variable | Inserts |
|---|---|
user_first_name | The visitor’s first name (the first word of their name). |
user_full_name | The visitor’s full name. |
user_name | The visitor’s name. |
user_email | The visitor’s email address. |
Where you can use variables
Variables are substituted inside the embedded widget and its popups. You can add them to these fields: Widget content, under Settings → Public Portal & Widget → Widget, in the Text & labels section:- Title
- Description
- Satisfaction prompt title
Variables apply in the embedded widget and its popups only. They are not filled in on your standalone hosted portal pages, so keep variables to widget and popup text rather than content a portal visitor reads directly.
Add a variable
Open a text field that supports variables
For the widget greeting, go to Settings → Public Portal & Widget → Widget and open the Text & labels section.
Type your text with a variable and a fallback
Add the variable where you want the personal detail to appear. For example, set the Title to 
Hi {user_first_name|there} 👋.
Save your changes
A save bar appears at the bottom of the page once you edit a field. Click Save changes to make it live.
Use variables in popups and surveys
The same{variable|fallback} syntax works in your popups and survey questions.
In a popup, open Settings → Public Portal & Widget → Outbound messages, then create or edit a message and add a variable to its Message or Question field. For an NPS message you can also personalize the Follow-up prompt.

Good to know
- Personalization needs an identified visitor. The variable is only replaced with real data when Sleekplan knows who the visitor is. Anonymous visitors, and the widget preview in your settings, show the fallback.
- A fallback is not optional in practice. Because many visitors are anonymous, the fallback is what most people see. Write it as a complete, natural message.
- Only the four variables above are recognized. Any other name falls back.
- Not for the standalone portal. Variables are a widget and popup feature.
Related
Widget home screen
Choose which section a visitor lands on when they open the widget.
Widget action screen
Build a launcher of quick-action tiles for the widget.
End-user accounts
How visitors sign in and get identified, which is what unlocks personalization.
Custom code
Go further and inject your own HTML, CSS, and JavaScript into your portal.
