This documentation URL will be retired soon. Start using the Ranla API at https://api.ranla.ai. Docs: docs.ranla.ai.

On-site messages

Show banners or modals to anonymous visitors on your marketing site with Ranla’s tracking snippet. Collect an email on the message itself, or send people to a link—and when someone identifies in your product, Ranla can stitch the visit to a contact.


What you get

  • Anonymous reach — Message people before they have an email in Ranla
  • Page rules — Show on selected paths (for example pricing or blog)
  • Path-aware offers — Separate messages per path (pricing vs blog vs docs) with different copy and After submit URLs
  • When to show — Immediately, exit intent, after scroll %, or after a delay
  • Email capture or link — Collect email on the banner/modal, or open a URL
  • After submit URL — Optional link after a successful capture (thank-you page, PDF, booking link)
  • Automation hook — Capture fires on_site.email_captured so an automation can send the asset by email
  • Acquisition report — See which paths create contacts (Growth → On-site → Acquisition)
  • Identify stitch — Call stx.identify() after signup in your app so later email can continue the conversation

On-site messages are not a replacement for email automations. They are the on-site channel next to lifecycle and transactional mail.


Prerequisites

  1. A Ranla account on app.ranla.ai
  2. The marketing-site tracking snippet installed (/t.js for your account)
  3. Permission to edit Growth → On-site in the dashboard

Install the snippet

  1. Open Home (workspace setup) or Conversions → Install / tracking setup in the app.
  2. Copy the Ranla tracking snippet for your account.
  3. Paste it on the marketing site you want to message (every page where messages should appear).

The snippet loads the tracker and evaluates active on-site messages for the current URL.


Create a message

  1. Open Growth → On-site.
  2. Create a message (banner or modal).
  3. Set copy, theme, and where it appears (page path prefix).
  4. Choose when to show: immediately, exit intent, after scroll %, or after a delay.
  5. Choose the call to action:
    • Link — button label + URL (visitor clicks and goes there)
    • Collect email — email field + submit label; optional After submit URL
  6. Publish when ready.

Draft messages do not show to visitors. Visitors who already identified do not see messages.

When someone submits an email on a Collect email message, Ranla creates or updates the contact, links the anonymous visitor, counts the message as Identified, removes the banner, and fires the product event on_site.email_captured.

Path-aware offers

Create separate messages for different paths instead of one generic banner:

Path Example offer
/pricing Collect email → After submit = demo booking
/blog Collect email → After submit = checklist PDF
/docs Link or capture → trial signup

Use a path prefix rule on each message so the right offer shows on the right page.


After submit + deliver by email

After submit is a normal web link. If set, the browser goes there after a valid email submit. If empty, the message dismisses and the visitor stays on the page.

To email the asset (recommended for magnets):

  1. Open Automations and create a flow triggered by on_site.email_captured (or use the On-site lead magnet template).
  2. Send the PDF / checklist / next step from that automation.
  3. Optionally still set After submit for an instant thank-you page.

Event properties include path, message_id, and visitor_key when available.


Acquisition report

Open Growth → On-site → Acquisition to see:

  • Which paths created contacts in the last 90 days
  • Which messages converted the most Identified visitors

Identify visitors

Even with on-message capture, call identify when someone signs up or logs in in your product so Ranla can attach prior anonymous activity to the contact:

stx.identify({ email: '[email protected]' })

Exact helper names follow the snippet your account installs. Identify after you know the email.


Common questions

Who sees on-site messages?

Anonymous visitors on pages that match your page rules, as long as the Ranla tracking snippet is installed and the message is published. Visitors who already identified do not see them.

Can the banner collect email?

Yes. Set the call to action to Collect email. The visitor enters an address, Ranla creates or updates the contact, credits Identified, and removes the message.

What is After submit?

An optional URL. After a successful email capture, the browser goes to that link—for example a thank-you page, PDF download, or booking page. Leave it empty to dismiss the message and stay on the page.

How do I email a lead magnet after capture?

Create an automation triggered by on_site.email_captured (or use the On-site lead magnet template). Capture creates the contact and fires that event; the automation sends the asset.

Can I show different offers on pricing vs blog?

Yes. Create separate messages with different path prefixes, copy, and After submit URLs. Prefer path-aware offers over one global banner.

When can a message appear?

Immediately on the page, on exit intent, after a scroll percent, or after a delay in seconds. Set this under When to show on the message.

How do anonymous visits become contacts?

Either Collect email on the message, or call identify with their email after signup in your product. Ranla stitches prior anonymous activity to that contact either way. Growth → On-site → Acquisition shows which paths created contacts.

Do on-site messages replace email automations?

No. They are the on-site channel next to lifecycle and transactional email. Use After submit for an instant link; use an automation on on_site.email_captured for durable follow-up.