Organizations enable multi-tenant functionality where users can create workspaces, invite team members, and collaborate with role-based permissions.
Perfect for: SaaS applications, team collaboration tools, B2B platforms, and enterprise applications.
# Set billing mode to organization-based
NEXT_PUBLIC_BILLING_MODE="organization"
# Enable organization pages
NEXT_PUBLIC_ENABLED_PAGES="organization,invitation,account,settings,subscription"
# Email service required for invitations
RESEND_API_KEY="re_your_resend_api_key"
EMAIL_FROM="noreply@yourdomain.com"Organization features automatically appear in user account at /[locale]/account/organizations.

Key concept: One user can belong to multiple organizations with different roles in each organization.
Organization structure:
User experience:
Organization Selection Interface:
User visits /[locale]/account/organizations to see all their organizations.
Click "Create Organization" button (if user has permission).
Creator automatically becomes the organization owner with full permissions.
Creation limits: By default, users cannot create organizations (allowUserToCreateOrganization: false). Only admins can create organizations, or this setting can be changed.
Location: /[locale]/account/organizations/[id]/edit
Available settings:
Organization Members Management:
Member Roles Management:
Organization owner/admin visits /[locale]/account/organizations/[id] and clicks "Invite Members".

Invitee receives email with invitation link and organization details.
Invitee clicks link, goes to /[locale]/account/invitations/[id], and can accept or decline.

Full organization control:
Limitations: Only one owner per organization
Invitation limits: 10 pending invitations per organization (configurable)
Invitation features:
User invitation page: /[locale]/account/invitations
Detailed Members Management Interface:
NEXT_PUBLIC_BILLING_MODE="organization"How it works:
Best for: Team subscriptions, B2B SaaS, collaborative tools
With organization billing:
Subscription pages:
/[locale]/account/billing/subscription - Current organization's subscriptionThe organization system uses Better Auth's organization plugin:
// In src/lib/better-auth/auth.ts
organization({
invitationLimit: 10, // Max pending invitations
membershipLimit: 10, // Max members per organization
allowUserToCreateOrganization: false, // Only admins can create
async sendInvitationEmail(data) {
const inviteLink = `${env.NEXT_PUBLIC_APP_URL}/invitations/${data.id}`
// Send via notification service
await createTypedNotificationService({
userId: invitedUser.id,
type: NotificationTypeConst.organization_invitation,
metadata: {
organizationId: data.organization.id,
organizationName: data.organization.name,
invitedBy: data.inviter.user.name,
role: data.role,
}
})
}
})Key configuration:
src/app/[locale]/(app)/account/
├── organizations/
│ ├── page.tsx # List all user's organizations
│ └── [id]/
│ ├── page.tsx # Organization details & members
│ └── edit/
│ └── page.tsx # Organization settings
└── invitations/
├── page.tsx # List pending invitations
└── [id]/
└── page.tsx # Accept/decline specific invitation
Admin creates organization from /[locale]/account/organizations.
Owner goes to organization settings and invites members by email.
Invited users receive emails, visit invitation page, and accept to join.
All organization members can now access shared organization features and data.
User can:
"Cannot create organization" error?
allowUserToCreateOrganization settingInvitation emails not arriving?
RESEND_API_KEY is configuredEMAIL_FROM domain is verifiedOrganization features not visible?
NEXT_PUBLIC_BILLING_MODE="organization"NEXT_PUBLIC_ENABLED_PAGES includes "organization,invitation"Built-in security features:
Permission validation:
Administration Interface:
All working? Your application now supports full multi-tenant organizations with team management and role-based permissions!