Cross-platform framework · platform guide

The backend for React Native.

Amba gives a bare React Native app its whole backend from one pure-JS SDK: auth, user data, push campaigns, streaks, gamification, and analytics — no native code of its own to link, AsyncStorage is the only required peer you add. If you want the battle-tested defaults instead, Firebase and Supabase are legitimate choices; the comparisons linked below say exactly where each wins.

Get an API key All platformsupdated June 12, 2026
copy, paste, build:

"Best backend for React Native" searches still surface answers written for a different era — native modules to link, pods to install, separate SDKs for auth, push, and analytics. @layers/amba-react-native is deliberately simpler: a pure-JS HTTP client covering the full 32-module surface (auth with Apple/Google/anonymous and account linking, typed collections with vector search, push registration, streaks, XP, leaderboards, currencies, friends, groups, messaging, feeds, flags, events). There is no native module to autolink for the SDK itself; the only required peer is @react-native-async-storage/async-storage, which autolinks like any modern RN dependency. Identity persists securely on device, and everything the SDK talks to was provisioned by your coding agent over MCP.

quickstart

How do I add Amba to a React Native app?

Install (bare React Native)

npm install @layers/amba-react-native @react-native-async-storage/async-storage

Pure JS — no pods to edit, nothing of the SDK’s own to autolink. AsyncStorage autolinks as usual.

Configure + first call

import { Amba } from '@layers/amba-react-native';

await Amba.configure({ projectId: 'proj_…', clientKey: 'amba_ck_…' });
await Amba.auth.signInAnonymously();
await Amba.events.track('app_opened');

Push registration — bring your notifications library

import { Platform } from 'react-native';
import * as Notifications from 'expo-notifications';
import { Amba } from '@layers/amba-react-native';

const { data: token } = await Notifications.getDevicePushTokenAsync();
await Amba.push.register(token, Platform.OS === 'ios' ? 'apns' : 'fcm');

The SDK ships no native push module by design — capture the token with the notifications library you already use, then register it.

capability coverage

What does Amba ship for React Native developers?

surfacestatusnotes
Auth & identity (Apple, Google, anonymous, link)Yes — built inAnonymous-first sessions, social sign-in via your platform auth flow’s identity token, account linking, and secure on-device persistence.
Push notifications (iOS + Android, scheduled)PartialCampaigns, segment targeting, and scheduling are built in server-side. The SDK registers tokens but ships no native capture module — you obtain the APNs/FCM token with your notifications library and pass it to Amba.push.register.
Data collections + vector searchYes — built inTyped collections with per-column where filters, pagination, and vector search.
Streaks (declarative, grace, timezone)Yes — built inServer-side streak rules; the SDK reads state and reports activity.
Leaderboards, XP & weekly leaguesYes — built inXP rules, achievements, challenges, leaderboards, and leagues.
Virtual economy + subscriptions / IAPPartialCurrencies, inventory, catalog, and entitlement state ship; store receipt validation composes with RevenueCat rather than replacing it.
Social graph, feeds & group chatYes — built inFriends, groups, messaging, feeds, reviews, and moderation.
Product analytics (events, funnels, retention)Yes — built inIdempotent event tracking; funnel and retention queries run server-side.
Feature flags & remote configYes — built inFlags and config namespaces ship in the SDK.

Surface verified against the published package, June 2026. Using Expo? @layers/amba-expo wraps this SDK with SecureStore persistence, sign-in wrappers, and a config plugin — see /backend-for/expo.

the honest part

When is Amba not the right call?

Firebase is the battle-tested default
A decade of SDK maturity, free FCM at any scale, and the deepest community answer pool in mobile. If you want a proven general-purpose datastore and will build engagement features yourself, Firebase is the safer foundation — the honest head-to-head is at /compare/firebase.
Supabase wins on raw SQL
If your app is built around relational queries, joins, and SQL you write yourself, Supabase is the better-shaped tool. Amba’s collections are typed and filterable with vector search, but they are not a SQL console — see /compare/supabase.
No bundled native push capture
The SDK deliberately ships zero native code, which means it will not capture the device push token for you in bare RN — you keep your existing notifications library for that one step. Teams that want one-call capture get it via the Expo wrapper.
the agent path

Can an AI agent set this up end to end?

Yes. Amba’s hosted MCP server at https://mcp.amba.dev/mcp (Streamable HTTP) exposes the whole backend as tool calls. amba_developer_signup mints a developer token and a provisioned project — client key and server key included — with no browser, and the project goes active in about ten seconds. The agent provisions the project over MCP, defines the schema and engagement rules as tool calls, and emits the projectId + clientKey for Amba.configure — the SDK install is the only step that touches your repo.

questions

Amba + React NativeFAQ

What is the best backend for a React Native app?

It depends on the app’s shape. Firebase is the battle-tested general-purpose default; Supabase fits SQL-centric apps; Amba fits engagement-driven consumer apps — streaks, push campaigns, segments, gamification, social — installed by an AI agent over MCP. The head-to-head comparisons at /compare/firebase and /compare/supabase include where each beats Amba.

Is Amba a Firebase alternative for React Native?

For engagement-driven apps, yes. Amba covers auth, data, and push like Firebase, then adds the layer Firebase leaves you to build: streaks, segments, scheduled campaigns, XP, and an in-app economy as first-class APIs. Firebase keeps the edge on ecosystem maturity and raw scale — the full comparison is at /compare/firebase.

Does the SDK require linking native modules?

Not for the SDK itself — @layers/amba-react-native is a pure-JS HTTP client with no native code, so there is nothing of its own to autolink and no pod changes. The one required peer, @react-native-async-storage/async-storage, autolinks automatically on any modern React Native version.

How does push work in bare React Native?

You capture the APNs or FCM device token with the notifications library you already use, then call Amba.push.register(token, platform). Campaign creation, segment targeting, and scheduling all happen server-side. The SDK intentionally ships no native capture module, so it never constrains your notifications setup.

I’m using Expo — should I use this package?

Use @layers/amba-expo instead. It re-exports this SDK and adds SecureStore-backed token persistence, one-call Sign in with Apple and Google wrappers, push-token capture via expo-notifications, and a config plugin for prebuild. The guide is at /backend-for/expo.

sources

Sources for this guide

start in 30 seconds

Hand the docs to your agent.
Ship by lunch.

Read the docs