Realanalytics
Meta Ads attribution, now the core of the platform

Analytics defined in code. Attribution you can audit.

Realanalytics turns event schemas and dashboards into TypeScript that ships with your app — and reconciles every dollar of Meta Ads spend against verified conversions and revenue.

bun add @realanalytics/sdk · free tier, no credit card

analytics/events.tstypescript
import { defineEvents, defineDashboard } from '@realanalytics/sdk'

export const events = defineEvents({
  signup_started: {
    plan: 'string?',
  },
  signup_completed: {
    plan: 'string',
    utm_source: 'string?',
  },
  purchase_completed: {
    revenue: 'number',
    currency: 'string',
  },
})

export const overview = defineDashboard({
  id: 'overview',
  title: 'Acquisition',
  widgets: [
    { type: 'metric', event: 'signup_completed', label: 'Signups' },
    { type: 'funnel', steps: ['$pageview', 'signup_completed', 'purchase_completed'] },
  ],
})
Attribution — last 7 daysreconciled with Meta

Spend

$7,065

Verified revenue

$23,890

Blended ROAS

3.38×

CampaignSpendCPAROAS
Prospecting — Lookalike 1%$4,210$48.952.95×
Retargeting — 30d visitors$1,875$29.304.97×
Brand — Broad$980$54.442.18×

168 conversions · 168 ledger entries · 0 unverified

Code is the source of truth

Event schemas, dashboards, and funnels live in your repo. Changes ship through pull requests, not settings pages.

Verified conversions

Revenue from Stripe, your API, or your CRM lands in a conversion ledger — attribution is computed from evidence, not pixels alone.

Privacy-aware by default

Explicit consent enforcement, URL redaction, and first-party tracking in the browser and on the server.

Analytics as code

Your tracking plan is a TypeScript file, not a spreadsheet

Schemas, dashboards, and funnels are declarative config in your repo. They're type-checked in CI, reviewed in pull requests, and deployed with the rest of your application.

Typed event schemas

Define every event and property once in TypeScript. The SDK autocompletes against it and rejects drift at compile time.

PR-reviewable dashboards

Dashboards are declarative config, so a chart change is a diff a teammate can approve — with full history in git.

Deploy previews and diffs

Every deploy shows exactly what changes against production and flags breaking schema edits before they land.

deploy previewconsole
$ realanalytics deploy --preview

  Comparing local config against production…

  ~ events.signup_completed
      + property utm_source: string?
  + dashboards/acquisition
      + widget funnel "Landing → Paid"
  ✓ 2 changes, 0 breaking — safe to deploy

$ realanalytics deploy
  ✓ Deployed in 3.2s

Paid attribution

Know which Meta campaigns actually make money

Pixels report what platforms claim. Realanalytics reconciles ad spend against a ledger of verified conversions and revenue — then sends the truth back to Meta.

A ledger, not a guess

Conversions and revenue from Stripe, your API, and Attio are recorded in a durable conversion ledger with retries and replay — every attributed number traces back to a verifiable entry.

Spend reconciliation

Meta spend syncs daily and is reconciled against delivered conversions, so CPA and ROAS are computed from what actually happened — and discrepancies are surfaced, not hidden.

Multi-model attribution

First-touch, last-touch, and weighted models are versioned and replayable. Click IDs and campaign dimensions are captured with consent, stitched across sessions.

Conversions API delivery

Verified conversions flow back to Meta via CAPI with test/live isolation, idempotent delivery, and a full retry audit trail.

Spend reconciliation — Maymeta · daily sync

Prospecting — Lookalike 1%

$4,210 spend
86 verified conversions$12,430 revenue2.95× ROAS

Retargeting — 30d visitors

$1,875 spend
64 verified conversions$9,320 revenue4.97× ROAS

Brand — Broad

$980 spend
18 verified conversions$2,140 revenue2.18× ROAS
capi delivery: 168 sent · 0 failed · test/live isolated

Governance

Schema governance that runs in CI, not in meetings

The event catalog, versioning, and debugging tools that keep a tracking plan trustworthy as your team and your schema grow.

Event catalog

Every event, property, and owner documented automatically from your schema — no stale tracking plans in spreadsheets.

26 events · 3 pending review

Schema versioning & lint

Versioned schemas with a lint command in CI that catches unknown events, missing properties, and naming drift.

$ realanalytics lint — 0 errors

Event debugger

Inspect live events as they arrive, with validation results and payloads — see problems before your dashboards do.

live · validating against v14

SDK

Tracking that respects the browser and the user

One typed client for the browser and the server. Autocapture covers pageviews, clicks, forms, errors, and web vitals — and consent decides whether anything is sent at all.

  • Explicit consent enforcement — events are dropped, not queued, without it
  • URL redaction strips tokens and identifiers before ingestion
  • Browser and server SDKs share one schema and one event stream
  • First-party, cookieless by default, under 5KB in the browser
$pageview$click$form_submit$error$web_vital+21 more autocaptured
app/analytics.tstypescript
import { createClient } from '@realanalytics/sdk'

const analytics = createClient({
  publicKey: 'pk_live_xxx',
  consent: { default: 'denied' },
})

// Call only after your CMP has recorded this visitor's choice
analytics.setConsent({
  analytics: true,
  adUserData: false,
  adPersonalization: false,
  recordedAt: new Date().toISOString(),
  source: 'cmp:your-provider',
})

// Browser events describe intent, never verified conversions or revenue
analytics.track('signup_started', { plan: 'pro' })

How it works

From schema to reconciled spend in three steps

01

Define

Write event schemas and dashboards in TypeScript alongside your application code.

analytics/events.ts

02

Deploy

Ship through your existing workflow. Preview the diff, merge the PR, and the CLI deploys with your app.

realanalytics deploy

03

Measure

Dashboards render from your config while ad spend is reconciled against verified conversions.

CPA · ROAS · funnels

Pricing

Start free, upgrade when it earns its keep

Every plan includes typed schemas, dashboards as code, and the event catalog. No credit card to start, no sales call to see prices.

Vibe Check

$0/month

  • 10k events/month
  • 3 dashboards
  • 1 user
  • Community Discord
Most popular

Ship It

$29/month

  • 100k events/month
  • Unlimited dashboards
  • 1 user
  • Email support

Main Character

$99/month

  • 1M events/month
  • Unlimited dashboards
  • 5 team members
  • Priority support

VC Money

Custom

  • Unlimited everything
  • On-prem option
  • SLA guarantees
  • SOC 2 compliance
  • Dedicated support

Paid plans start with a 14-day trial. Bootstrapping? Email us — we offer startup discounts.

FAQ

Common questions

Those are dashboards you configure by clicking. Realanalytics is analytics you define in code: schemas and dashboards live in your repo, changes go through pull requests, and deploys are diffed against production. If you already treat infrastructure as code, this is the same discipline applied to analytics.

The SDK captures click identifiers and campaign dimensions with consent, and stitches identity across sessions. Conversions and revenue are recorded in a durable ledger from Stripe, your API, or your CRM. Attribution models run over that evidence, spend syncs from Meta daily, and verified conversions are delivered back through the Conversions API with a full audit trail.

Consent is enforced at the SDK level — without it, events are not sent. URLs are redacted before ingestion, tracking is first-party and cookieless by default, and you control exactly which autocapture features are enabled.

You get warnings at 80% and 100% of your quota. We never cut you off mid-month — events over the limit queue until the next cycle or until you upgrade.

Yes. Import scripts cover the major platforms, and because your schema is explicit TypeScript, the migration doubles as a cleanup of your tracking plan. Most teams finish in a day, and we help for free.

Something else? Ask in Discord

Ship analytics you can code-review

Define your first schema, deploy it with your app, and see your Meta spend reconciled against real conversions.