Overview of Sora UI's architecture — design philosophy, monorepo packages, 3-tier registry layout, and docs site self-hosting.
Sora UI is designed as an open-source, motion-first component system built with a dual-comprehension philosophy: UI components whose behavior, accessibility constraints, animation semantics, and composition rules are directly understandable by both developers and AI assistants.
It combines an open copy-paste registry architecture with structured metadata served via an MCP server, offering flexible primitives across multiple headless foundation libraries.
prefers-reduced-motion support.Sora UI is organized as a Turborepo monorepo with dedicated apps and modular packages:
apps/www: Built with Next.js (App Router) and Fumadocs. Serves the documentation, component previews, theme switcher, and JSON registry endpoints.apps/xmcp: A standalone MCP server delivering real-time search, documentation, and installation schemas to AI assistants (Cursor, Claude Code, VS Code, Windsurf).packages/db: Database layer using Drizzle ORM and Postgres, powering docs authentication, starred components, and user bookmarks.packages/auth-ui: Authentication views and state integration using better-auth.packages/ui: Shared design tokens, Tailwind configuration, and utility functions used across internal applications.packages/www-cli: Internal development utilities including automated registry generation and health audit commands (bun run doctor).Components are distributed via an open, copy-paste registry following the shadcn distribution schema. The registry is structured into three distinct tiers:
registry/primitives/): Low-level, composable building blocks focused on motion and gesture interactions powered by Framer Motion / Motion.registry/ui/): Standard application UI elements (dialogs, dropdowns, inputs, tooltips) wired to battle-tested headless primitives like Radix UI or Base UI for full WAI-ARIA compliance.Sora UI's documentation site keeps sign-in sessions and bookmarks in a Postgres database. The schema and client live in packages/db, built on Drizzle ORM and postgres.js.
You only need a database if you enable auth. Browsing the docs, blog,
catalog, and registry works with zero environment variables. Set
NEXT_PUBLIC_ENABLE_AUTH="true" to turn on sign-in and bookmarks.
Sponsored by Neon
Sora UI's production database runs on Neon — serverless Postgres with branching, autoscaling, and scale-to-zero. Neon sponsors Sora UI's infrastructure.
Neon is the provider we recommend for self-hosting Sora UI. It fits the way this app talks to Postgres:
Neon gives you two URLs for the same database. They differ only by the -pooler suffix in the hostname:
| Use | Variable | Hostname |
|---|---|---|
| Runtime (pooled) | DATABASE_URL | ep-xxx-pooler.<region>.aws.neon.tech |
| Migrations (direct) | DATABASE_URL_DIRECT | ep-xxx.<region>.aws.neon.tech |
Both use port 5432 and require sslmode=require:
Copy both URLs from the Neon console with the Connect button. Enable
Connection pooling for DATABASE_URL, then disable it for
DATABASE_URL_DIRECT.
The Neon CLI can pull the pooled and direct URLs as DATABASE_URL and
DATABASE_URL_UNPOOLED:
This project uses DATABASE_URL_DIRECT instead of Neon's
DATABASE_URL_UNPOOLED name, so copy the unpooled value into
DATABASE_URL_DIRECT in apps/www/.env.
Set these in apps/www/.env:
| Variable | Required | Description |
|---|---|---|
NEXT_PUBLIC_ENABLE_AUTH | Yes, for auth | Set to "true" to enable sign-in and bookmarks |
DATABASE_URL | Yes, for auth | Pooled Postgres URL used at runtime |
DATABASE_URL_DIRECT | Only for migrations | Direct Postgres URL used by drizzle-kit |
Schema lives in packages/db/src/schema. Run migrations from the package root:
drizzle-kit prefers DATABASE_URL_DIRECT and falls back to DATABASE_URL. Always give it a direct connection — running migrations through a transaction-mode pooler fails in confusing ways.
Other schema commands:
Any Postgres provider works — the schema is plain Postgres, and the client connects with prepare: false so it stays compatible with transaction-mode poolers (Neon's -pooler endpoint, Supabase's port 6543).
Point DATABASE_URL at a pooled endpoint and DATABASE_URL_DIRECT at a direct one, then apply the migrations above.
Sora UI originated as a fork of Animate UI by @imskyleen, from which it inherited early monorepo boilerplate and documentation layout conventions.
Since then, the project has been fully re-architected with independent component implementations, an AI-native MCP server, a 3-tier registry architecture, and dedicated fullstack docs infrastructure. Component implementations are developed independently or credited in their respective documentation pages under ## Credits.
Original Sora UI code is distributed under the MIT License. Portions derived from upstream remain subject to their original licenses:
Portions Copyright (c) 2025 Elliot Sutton (Animate UI — https://github.com/animate-ui/animate-ui)
Full license text is available on the License page. If something looks like it's missing credit, please reach out.
Other Animated Component Libraries (shadcn-Style Alternatives)
A comparison of open-source, copy-paste animated component libraries for React and Vue — Magic UI, Aceternity UI, React Bits, Inspira UI, and more — for teams evaluating alternatives to Sora UI.
License
Terms of use and licensing for Sora UI and upstream components.
Built by Axyl. A motion-first component registry for React.
Last updated: 10/26/2026
Help keep SoraLabs moving.
Every contribution helps us build and maintain open-source tools for the community.
Sponsor on GitHub