General 1,678 installs

Organizations (B2B SaaS)

by clerk/skills

Clerk Organizations for B2B SaaS - create multi-tenant apps with org switching, role-based access, verified domains, and enterprise SSO. Use for team…

Skill content

Organizations (B2B SaaS)

STOP - prerequisite. Organizations must be enabled before any org-related API, hook, or component works. Two paths: (1) Dashboard → Organizations settings, or (2) clerk enable orgs (see "Agent-first: Programmatic org management" below). Pick the Membership mode deliberately: Membership required (default since 2025-08-22) routes signed-in users through the choose-organization task and disables personal accounts, while Membership optional keeps personal accounts available for B2C + B2B coexistence. Pick optional if you need personal subscriptions alongside org subscriptions.

Version: This skill targets current SDKs (@clerk/nextjs v7+, @clerk/react v6+ - Core 3). Core 2 differences are noted inline with > **Core 2 ONLY (skip if current SDK):** callouts - see clerk skill for the full version table.

Quick Start

- Enable Organizations - via Dashboard → Organizations settings or clerk enable orgs (see Agent-first section). Pick Membership required (B2B-only) or Membership optional (B2C + B2B).

- Create an org - via <OrganizationSwitcher />, <CreateOrganization />, or programmatically with clerkClient().organizations.createOrganization().

- Protect routes - read orgId / orgSlug from auth() and gate with has({ role }) or has({ permission }).

- Manage members - send invitations via Backend API or the built-in <OrganizationProfile /> tab.

- Cap membership - set maxAllowedMemberships at org creation or pick a seat-limited Billing Plan (see clerk-billing skill).

What Do You Need?