Set Up In-App Messages (SDK) in Customer.io

Customer.io partner logo

Table of Contents

Summarize this documentation using AI

This banner was added using fs-inject

Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Overview

If you’re running Customer.io for a D2C brand, in-app is one of the fastest ways to lift repeat purchase and cart recovery—because it hits while the shopper is already in the buying context. If you want help pressure-testing your tracking plan and orchestration, you can book a strategy call and we’ll sanity-check the setup like an operator would.

In-app messaging only works as well as your SDK instrumentation. The win isn’t “show a banner”—it’s reliably stitching identity (anonymous → logged-in), capturing the right commerce events, and targeting messages so they feel like assistance, not noise.

How It Works

In practice, in-app messages succeed when the app sends clean, consistent events into Customer.io and the SDK can confidently decide who should see a message and when. Most retention programs we’ve seen break at identity (duplicate profiles) or event semantics (different event names across iOS/Android/web).

  • SDK initializes with your Customer.io site ID/config so the app can receive in-app payloads and report engagement back (impressions, dismissals, clicks).
  • Anonymous session tracking starts immediately (pre-login browsing, PDP views, add-to-cart). This is where cart recovery and product discovery prompts earn their keep.
  • Identify on login (and after checkout) to stitch anonymous activity to the known customer profile. Without this, your “viewed product → bought” logic gets split across people and targeting becomes unreliable.
  • Track events with consistent properties (SKU, product_id, cart_value, currency, category, variant, quantity). These properties become your segmentation and message personalization inputs.
  • Customer.io evaluates targeting rules (segments + recent events + attributes) and delivers an in-app message to eligible devices/sessions. Your SDK renders it and reports engagement so you can optimize.

Real D2C scenario: A shopper adds a cleanser and moisturizer to cart on mobile, then hesitates on the shipping step. If you track checkout_started and checkout_step_viewed, you can trigger an in-app message on the next session: “Still deciding? Free shipping over $50—your cart is at $46.” That only works if cart value and currency are tracked as properties and the profile is correctly identified.

Step-by-Step Setup

Before you touch campaigns, lock down the SDK foundation. You’re aiming for: (1) correct identity stitching, (2) predictable event names, and (3) enough properties to personalize without over-engineering.

  1. Install the Customer.io SDK in your app(s)
    Add the appropriate SDK for iOS/Android/React Native/etc. and initialize it on app start with your workspace credentials.
  2. Decide your identity rules (this is the make-or-break step)
    Pick a single canonical user identifier (usually your internal customer ID). Use email as an attribute, not the primary ID, unless your system is truly email-first.
  3. Implement identify() at the right moments
    Call identify immediately after login/signup, and also after checkout if guest checkout can convert to an account. Include key attributes you’ll segment on (e.g., email, phone, first_order_date, lifetime_value, loyalty_tier).
  4. Track a minimum viable commerce event schema
    At minimum, implement:
    • product_viewed (product_id, sku, name, category, price)
    • add_to_cart (product_id, sku, quantity, price, cart_value)
    • checkout_started (cart_value, item_count)
    • purchase (order_id, revenue, currency, items[])
    Keep naming identical across platforms. Don’t let Android call it AddedToCart while iOS calls it add_to_cart.
  5. Confirm the SDK is receiving in-app messages
    Use a test segment (internal testers) and a simple in-app message to validate rendering, deep links, and dismissal behavior.
  6. Wire deep links and attribution
    When someone taps the in-app CTA, send them to the exact screen (cart, PDP, reorder page) and track a click event (or rely on SDK engagement callbacks if available). This is how you learn which prompts actually drive revenue.
  7. QA identity stitching end-to-end
    Do a full flow: browse anonymously → add to cart → close app → open app → login → verify the profile in Customer.io shows the pre-login events. If it doesn’t, fix this before building more.

When Should You Use This Feature

In-app messages are best when timing and context matter more than reach. Email and SMS are great for pulling people back; in-app is great for converting them once they’re already present.

  • Cart recovery while they’re active: show a reminder when they return to the app within 24–72 hours of add_to_cart but no purchase.
  • Checkout friction fixes: if you track checkout steps, prompt help at high-drop steps (shipping, payment). This often outperforms generic “complete your order” nudges.
  • Second purchase acceleration: after a first purchase, trigger an in-app cross-sell when they view a complementary category (e.g., “Refill packs ship free with your next order”).
  • Reactivation moments: when a lapsed customer opens the app, welcome them back with a personalized offer or “what’s new” module—without blasting discounts to everyone.

Operational Considerations

The operational reality is that in-app is a coordination problem: product analytics naming, engineering release cycles, and retention segmentation all collide here. If you don’t set guardrails early, you’ll end up with noisy triggers and hard-to-debug performance.

  • Segmentation depends on event hygiene: if purchase sometimes fires twice or misses currency, your “high intent, no purchase” segments will be wrong and you’ll annoy buyers.
  • Identity stitching impacts frequency control: anonymous users can get hit repeatedly if you only cap frequency on identified profiles. Decide whether to cap by device/session too.
  • Data flow latency matters: if your events arrive late, “show message immediately after add_to_cart” becomes “show it next day,” which changes the experience. Validate timing in real conditions, not just in logs.
  • Orchestration across channels: coordinate in-app with push/email so you don’t double-tap. Example: if in-app converts the cart, suppress the cart abandonment email.
  • Property standardization: agree on a shared dictionary (product_id vs sku, revenue vs total, etc.). In practice, this is what keeps campaigns maintainable six months later.

Implementation Checklist

Use this as a pre-launch gate. If you can’t check these off, you’re likely to ship messages that look fine but don’t drive incremental revenue.

  • SDK installed and initialized on app open
  • identify() called on login/signup and correctly maps to a single canonical customer ID
  • Anonymous → identified activity merge verified with a real test flow
  • Core commerce events tracked with consistent names across platforms
  • Key properties included: product_id/sku, cart_value, currency, order_id, revenue
  • Deep links from in-app CTAs route to the correct screen
  • Engagement tracking confirmed (impression/click/dismiss)
  • Frequency caps defined (by user and, if needed, by device/session)
  • Suppression logic planned (e.g., don’t show cart prompts after purchase)

Expert Implementation Tips

These are the small decisions that usually determine whether in-app becomes a meaningful revenue lever or just another channel teams stop trusting.

  • Track “intent,” not just “actions.” Add events like viewed_shipping_step or properties like cart_value so you can tailor the message (shipping threshold, payment options, etc.).
  • Use SKU/product_id consistently and include variant. If you sell shades/sizes, variant-level tracking is what makes “Still want this?” messaging feel accurate.
  • Stitch guest checkout thoughtfully. If a user purchases as guest and later creates an account, make sure your system can reconcile those IDs—or your “post-purchase” in-app will misfire.
  • Design for the next screen. The CTA should land them exactly where conversion happens. “View cart” beats “Shop now” almost every time for cart recovery.
  • Start with one high-signal use case. Cart return + no purchase is usually the cleanest. Once the data is trusted, expand into cross-sell and reactivation.

Common Mistakes to Avoid

Most mistakes aren’t creative—they’re instrumentation and orchestration problems that quietly tank performance.

  • Calling identify() too late (or not at all), leaving pre-login cart activity stranded on an anonymous profile.
  • Inconsistent event names across platforms, creating “missing audience” issues where only iOS users qualify.
  • Missing currency/price properties, which breaks threshold logic and makes revenue reporting unreliable.
  • No suppression after conversion, so customers who already purchased still see cart nags on their next open.
  • Over-messaging new users because there’s no frequency cap or because anonymous profiles aren’t included in caps.
  • Assuming clicks equal impact: always measure downstream purchase rate and incremental lift, not just engagement.

Summary

If your SDK identity stitching and commerce events are clean, in-app messages become a reliable lever for cart recovery and repeat purchase. If they’re messy, you’ll spend cycles debugging segments and apologizing for irrelevant prompts. Get the tracking right first, then scale the playbook.

Implement Set Up In App with Propel

If you’re implementing in-app inside Customer.io, the highest-leverage help is usually upfront: a tight event schema, clear identity stitching rules, and suppression logic that prevents channel collisions. If you want an operator to review your tracking plan and map it to retention outcomes (cart recovery, second order, reactivation), you can book a strategy call and we’ll walk through what to instrument and how to QA it before you scale campaigns.

Contact us

Get in touch

Our friendly team is always here to chat.

Here’s what we’ll dig into:

Where your lifecycle flows are underperforming and the revenue you’re missing

How AI-driven personalisation can move the needle on retention and LTV

Quick wins your team can action this quarter

Whether Propel AI is the right fit for your brand, stage, and stack