BuildBaseBuildBase

Introduction

Everything you need to run a SaaS app — auth, billing, workspaces, permissions, and more.

BuildBase is SaaS infrastructure in one SDK. Authentication, billing, workspaces, permissions, email, and workflow automation — integrated and production-ready.

Note

Want to see it in action before reading docs? Try the live demo app.

SaaSOSProvider

Every BuildBase app starts with SaaSOSProvider — the root context provider that connects your React app to the BuildBase platform. "SaaS OS" stands for SaaS Operating System: the infrastructure layer your product runs on. Wrap your app once, and every hook and component in the SDK has access to your org, auth state, workspace, and permissions.

npm install @buildbase/sdk
import { ApiVersion } from '@buildbase/sdk';
import { SaaSOSProvider } from '@buildbase/sdk/react';

import '@buildbase/sdk/css';

export default function Providers({ children }) {
  return (
    <SaaSOSProvider
      serverUrl="https://api.console.buildbase.app"
      version={ApiVersion.V1}
      orgId="your-org-id"
      auth={{
        clientId: 'your-client-id',
        redirectUrl: 'http://localhost:3000/callback',
      }}
      locale="en"
    >
      {children}
    </SaaSOSProvider>
  );
}
import {
  useSaaSAuth,
  WhenAuthenticated,
  WhenUnauthenticated,
} from '@buildbase/sdk/react';

function App() {
  const { user, signIn, signOut } = useSaaSAuth();

  return (
    <>
      <WhenUnauthenticated>
        <button onClick={() => signIn()}>Sign In</button>
      </WhenUnauthenticated>
      <WhenAuthenticated>
        <p>Welcome, {user?.name}</p>
        <button onClick={signOut}>Sign Out</button>
      </WhenAuthenticated>
    </>
  );
}

What's included

FeatureWhat you get
AuthenticationSign-in, sign-out, social login, magic links
WorkspacesMulti-tenant workspaces with member management
BillingSubscription plans, checkout, trials, seats
CreditsConsumption-based billing with balance tracking
PermissionsRole-based access control
Feature FlagsGate features by plan or user
Pre-built UIDrop-in settings screens and page components
WebhooksReal-time event notifications
Push NotificationsBrowser push notifications
Internationalization8 locales with RTL support
Server SDKNode.js SDK for backend operations

Which docs do I need?

Most SaaS builders only need the SDK README on npm. It covers installation, all hooks, components, and pre-built UI — everything you need to ship.

These docs go deeper into patterns, composition, and server-side integration for teams with custom requirements.

I want to...Go to
Get started fastSDK README
Understand a specific featureThese docs (see table above)
Check the full APIAPI Reference
Fix an issueTroubleshooting

Next Steps

  • Installation — Install the SDK and configure the provider.
  • Quickstart — Build a working app with auth in 5 minutes.
  • SDK README — Full API reference on npm.