Documentation

Component Showcase

Every formatting and component option available in Superfunnel docs — use this as a reference when writing articles.

This page is a living reference. Every component, callout, layout, and typography pattern that you can use in any doc article is demonstrated here in one place.


Callouts

Five callout flavors. Use them to surface context that would get lost in a paragraph.

What's happening

This is an Info callout. Great for background context, definitions, or explaining why something works the way it does.

Pro tip

This is a Tip callout. Use it for shortcuts, best practices, or anything that makes a user's life easier once they know it.

Watch out

This is a Warning callout. Reserve it for actions that are hard to undo — data loss, billing changes, permission escalations.

Keep in mind

This is a Note callout. Good for caveats, version-specific behavior, or things that are true but easy to forget.

You're all set

This is a Check callout. Use it at the end of a tutorial step to confirm the user has everything in order before moving on.


Cards

Cards turn a list of links into a visual navigation grid. Each card supports an icon, description, and a destination URL.

Cards also work in 3-column grids:

Experiments

A/B test any element — headline, CTA, layout — with automatic traffic splitting.

Smart Traffic

ML-based routing that learns which variant converts best and shifts traffic automatically.

Terminal access

Raw API access for power users who want to script funnel operations programmatically.


Steps

Steps are the gold standard for tutorials. Each step gets an auto-numbered marker and a title.

Create your funnel

Go to Dynamic Pages → New Page. Give it a name and choose a template, or start from scratch with the AI Assistant.

Set your conversion goal

Open the page settings and define what counts as a conversion — a button click, a form submit, or a custom event you send from your backend.

Connect your ad account

Navigate to Settings → Ad Platforms and link Google Ads or Meta. Superfunnel will automatically pass gclid and fbclid through your funnel URLs.

Launch and monitor

Click Publish. Your page is live on your Superfunnel subdomain within seconds. Head to the Analytics tab to watch conversions flow in.

Tip

Set up a Zapier zap or webhook before you launch so leads land in your CRM the moment they convert.


Tabs

Tabs let you show the same concept in multiple contexts — language variants, platform differences, before/after — without duplicating prose.

superfunnel.track('lead_submitted', {
  email: 'user@example.com',
  funnel_id: 'funnel_abc123',
  value: 49.99,
})

Accordions

Accordions work well for FAQs, reference material, or anything the reader may want to skip on first pass.

Smart Traffic uses a multi-armed bandit algorithm to continuously allocate more traffic to the variant with the highest conversion rate. Unlike A/B tests that split traffic 50/50 until significance, Smart Traffic starts optimizing from day one — minimizing wasted spend on underperforming variants.


Code blocks

Shiki powers syntax highlighting with github-light / github-dark themes. Every common language works.

TypeScript

import { createHmac } from 'crypto'

export function verifyWebhook(
  payload: string,
  signature: string,
  secret: string
): boolean {
  const expected = createHmac('sha256', secret)
    .update(payload)
    .digest('hex')

  return Buffer.from(signature).equals(Buffer.from(expected))
}

SQL

SELECT
  f.id,
  f.name,
  COUNT(DISTINCT e.visitor_id) AS visitors,
  COUNT(DISTINCT CASE WHEN e.event = 'converted' THEN e.visitor_id END) AS conversions,
  ROUND(
    100.0 * COUNT(DISTINCT CASE WHEN e.event = 'converted' THEN e.visitor_id END)
          / NULLIF(COUNT(DISTINCT e.visitor_id), 0),
    2
  ) AS conversion_rate_pct
FROM funnels f
LEFT JOIN events e ON e.funnel_id = f.id
WHERE e.created_at >= NOW() - INTERVAL '30 days'
GROUP BY f.id, f.name
ORDER BY conversions DESC;

JSON

{
  "id": "evt_01HXQ7M3K9FZYR6D",
  "type": "lead.created",
  "created_at": "2024-01-15T14:30:00Z",
  "data": {
    "lead_id": "lead_abc123",
    "funnel_id": "funnel_xyz",
    "email": "jane@example.com",
    "name": "Jane Doe",
    "custom_fields": {
      "utm_source": "google",
      "utm_campaign": "brand-search"
    }
  }
}

Bash

# Deploy a new page variant via CLI
sf pages deploy \
  --funnel "high-intent-finance" \
  --variant "challenger-headline" \
  --traffic 20 \
  --env production

Tables

Tables are best for reference material — parameters, feature comparisons, event schemas.

API parameters

ParameterTypeRequiredDescription
eventstringEvent name, e.g. lead_submitted
api_keystringYour Superfunnel API key
properties.emailstringUser email for identity matching
properties.valuenumberMonetary value in USD
properties.funnel_idstringFunnel identifier from the dashboard
idempotency_keystringDeduplicate events sent more than once

Plan comparison

FeatureStarterGrowthScale
Dynamic pages525Unlimited
Monthly visitors10k100kUnlimited
A/B variants per page310Unlimited
Smart Traffic
Custom domain
Offline conversions API
LangChain agent access
SLA99.9%

Typography

All standard Markdown formatting is available and styled consistently.

Bold text draws the eye to the most important word in a sentence. Use it sparingly — if everything is bold, nothing is.

Italic text is good for titles, terms being introduced, or gentle emphasis that doesn't need to shout.

Strikethrough is useful when documenting deprecated behavior or removed options you still want to mention for context.

Inline code is for any literal value the reader might type or copy — field names, API keys, CLI flags, file paths like /etc/hosts.

Combine them: use paddingRight to compensate for scrollbar reflow, and never set ~~overflow: visible~~ on a fixed element.

Simplicity is the ultimate sophistication. A landing page should have one job, one message, one button.

Unordered lists

  • Conversion rate is the only metric that matters at launch
  • Visitors and session duration are vanity metrics until you have real traffic
  • Every element on the page is either helping or hurting conversion — nothing is neutral
    • Headlines carry ~80% of the persuasive weight
    • Social proof works best directly above the CTA
    • Form length is inversely correlated with conversion rate

Ordered lists

  1. Define your conversion goal before writing a single word of copy
  2. Build the minimal page that can test your core hypothesis
  3. Send real traffic — synthetic data doesn't convert the same way
  4. Read the session recordings before touching the heatmaps
  5. Change one thing at a time and give variants enough traffic to reach significance

Internal links use Next.js routing: read the Integrations guide.

External links open in a new tab automatically: Superfunnel app.


Frame

Frame adds a polished border and rounded corners to any content — great for screenshots, diagrams, or UI demos.

Screenshot or image would go here — drop any img tag or Image component inside Frame


YouTube

Embed any YouTube video by ID. The embed is fully responsive.


Nested components

Components compose. Here's a Step that contains a callout, a code block, and a card — exactly as you'd write a real integration tutorial.

Install the SDK

npm install @superfunnel/sdk

Note

The SDK requires Node.js 18 or later. It works in both ESM and CommonJS environments.

Initialize the client

import { SuperfunnelClient } from '@superfunnel/sdk'

export const sf = new SuperfunnelClient({
  apiKey: process.env.SUPERFUNNEL_API_KEY!,
  // Optional: enable LangSmith tracing
  langsmithProject: 'superfunnel-prod',
})

Never expose your API key client-side

Keep SUPERFUNNEL_API_KEY in your server environment. The SDK is designed for server-side use only.

Send your first event

await sf.track('checkout_started', {
  email: session.user.email,
  value: cart.total,
  currency: 'USD',
  items: cart.items.map(i => i.sku),
})

Verify in the dashboard

Go to Analytics → Event Stream and you should see checkout_started appear within 5 seconds of firing this call.


Horizontal rules

Use --- to visually separate major sections. Three hyphens on their own line.


That covers every component available today. If you need something that isn't here — a diagram renderer, a live code playground, a comparison slider — open a request and we'll build it.