LearnHouse
Open-source LMS with AI tutoring, real-time collaboration boards, live code execution, and built-in course monetization — self-hosted in minutes.
LearnHouse is a next-generation open-source learning management system that consolidates everything an educator, creator, or institution needs into a single self-hostable platform. It replaces the patchwork of a CMS, video host, LMS, and payment processor with one cohesive system — complete with a block-based content editor, real-time collaborative whiteboards, code execution environments with auto-grading, and context-aware AI assistants.
The platform is structured as a monorepo with four deployable apps: a Next.js frontend, a FastAPI/Python backend, a Hocuspocus real-time collaboration server, and an official CLI that handles setup, updates, backups, and local development with a single command. PostgreSQL stores structured data and vector embeddings, Redis handles session caching and real-time state, and content files can be served locally or via AWS S3.
LearnHouse has a tiered plan system (free through enterprise) that unlocks features like AI credits, analytics, payments, SSO, SCORM import, multi-organization tenancy, and audit logs. The core platform — including the editor, code execution, podcast support, and certification — is available to self-hosters under AGPL-3.0. Enterprise features such as SSO via WorkOS and multi-tenancy live in an ee/ directory under a separate commercial license.
Since its 1.0 release in March 2026, the project has shipped bi-weekly releases and grown to over 1,750 GitHub stars with an active Discord community, 19 contributors, and a 90+ repo health score reflecting sustained development velocity.
What You Get
- Block-based Course Editor - A Notion-like Tiptap-powered editor supporting text, embedded videos, images, file uploads, quizzes, code blocks, and interactive embeds in a unified drag-and-drop canvas.
- Code Playgrounds with Auto-grading - Real code execution across 30+ programming languages powered by CodeMirror, with AI-generated simulations, diagrams, and automatic grading of student submissions.
- Real-time Collaborative Boards - Live whiteboards backed by Yjs and Hocuspocus for group brainstorming, peer review, and instructor-led sessions — changes sync instantly across all connected learners.
- Multi-provider AI Integration - Context-aware AI assistants for content generation and quiz creation, configurable to use Google Gemini, OpenAI, Anthropic, Mistral, Ollama (local), AWS Bedrock, or any OpenAI-compatible endpoint via Pydantic AI.
- Discussions and Communities - Built-in community forums organized by course or organization, giving learners a space to ask questions, share progress, and interact with instructors.
- Assignments and Submissions - Create structured assignments, track submission status per student, and provide feedback — all within the same platform as the course content.
- Podcast Channels - Embed and manage audio content directly within the platform for on-the-go learning experiences alongside video and text modules.
- Certification Engine - Automatically generate and issue customizable digital certificates upon course completion with metadata-rich verification.
- Course Analytics Dashboard - Track student engagement, completion rates, quiz performance, and time-on-task with visual metrics; advanced analytics available on higher plans.
- Multi-language Support - Full i18n with 19 languages out of the box for global learner reach.
- Headless REST API - Full API access for custom integrations, white-label builds, and programmatic course management.
- Enterprise SSO and Multi-Org - Single sign-on via WorkOS OAuth providers, fine-grained RBAC, SCORM import, and multi-organization tenancy for institutions running multiple portals from one instance.
Common Use Cases
- Running a paid coding bootcamp - An instructor self-hosts LearnHouse, builds Python and JavaScript courses with live code execution and auto-graded submissions, and accepts payments via Stripe — all without per-transaction platform fees.
- Corporate onboarding and training - An HR team deploys LearnHouse internally, imports existing SCORM modules, configures SSO with their identity provider, and uses collaborative boards for synchronous team exercises.
- University open courseware - A university hosts public courses with assignment submission tracking, AI-assisted study support, automated certificate issuance, and analytics — retaining full control over student data under GDPR.
- Multi-school SaaS platform - An edtech startup runs multiple branded educational portals for different clients from a single LearnHouse enterprise instance using the multi-organization tenancy feature.
- Language and certification training - An independent educator publishes multilingual audio-first courses with podcast modules, community discussion forums, and completion certificates in 19 supported languages.
Under The Hood
Architecture LearnHouse follows a clean service boundary model organized as a monorepo: the Next.js web frontend, FastAPI API backend, Hocuspocus collaboration server, and CLI are independently deployable but developed together. The API is the system’s authority layer — it handles auth, RBAC, content, analytics, payments, and AI, while the collab server delegates access control back to the API via internal JWT validation. Configuration management is centralized through typed Pydantic config classes that read from environment variables, eliminating hard-coded secrets throughout the codebase. Enterprise features are isolated behind an ee/ directory boundary with runtime feature flag enforcement rather than forked logic, enabling clean open-core separation without duplicating business logic.
Tech Stack The backend runs FastAPI with Python 3.14, SQLModel and SQLAlchemy for ORM, Alembic for migrations, and pgvector for AI embedding storage in PostgreSQL. The frontend is Next.js 15 with React, Tailwind CSS, and Radix UI components, using Bun as the package manager and Turbopack for development builds. Real-time collaboration uses Hocuspocus with Yjs CRDT synchronization, with Redis caching ydoc state between flushes to PostgreSQL. The AI layer is provider-agnostic via Pydantic AI, supporting Google Gemini, OpenAI, Anthropic, Mistral, Ollama, AWS Bedrock, and OpenRouter through a single configuration switch. Stripe handles payments, WorkOS provides enterprise SSO, Sentry handles error monitoring, and AWS S3 or local storage serve content files.
Code Quality The API has an extensive test suite of 191 test files covering routers, services, security, auth, RBAC, and integrations — with a 90% coverage target enforced in CI via Codecov. Tests use in-memory SQLite with JSONB-to-JSON remapping to avoid requiring a live database, and mock external services including AI providers and S3. Error handling is explicit with typed Pydantic models, custom HTTP exceptions, and structured validation responses. The codebase uses Ruff for linting, strong type annotations throughout the Python backend, and ESLint with TypeScript strict mode on the frontend. CI is integrated via GitHub Actions with automatic Renovate dependency updates grouped by layer.
What Makes It Unique The combination of a block-based course editor with embedded live code execution — not just syntax highlighting but actual multi-language runtime with auto-grading — is rare in open-source LMS software. The AI layer stands out for its provider-agnostic design using Pydantic AI: switching from Gemini to a local Ollama model or AWS Bedrock requires only a configuration change, with no business logic tied to a specific vendor SDK. The addition of a first-party MCP server (Model Context Protocol) signals early investment in making LearnHouse courses queryable by external AI agents. The tiered plan system with per-feature enforcement at the API layer — rather than purely UI gating — provides a credible path for organizations to evaluate the OSS tier before purchasing enterprise licenses.
Self-Hosting
LearnHouse is released under the GNU Affero General Public License v3.0 (AGPL-3.0) for its core platform. AGPL-3.0 is a copyleft license with a network use clause: if you run a modified version of LearnHouse as a service and users interact with it over a network, you must publish your modifications under the same license. For organizations using LearnHouse unmodified or whose modifications they are comfortable open-sourcing, self-hosting is fully permitted — commercially and without royalties. Organizations needing to keep customizations proprietary, or requiring features like SSO, SCORM import, multi-organization tenancy, or audit logs, must acquire a commercial Enterprise License. The README explicitly notes that enterprise features are available under a separate Enterprise License alongside the AGPL core.
Running LearnHouse yourself requires PostgreSQL, Redis, and a server capable of running Docker containers — the CLI setup wizard automates configuration, but you own uptime, backups, and scaling. The npx learnhouse CLI provides commands for start, stop, update, backup, and diagnostics (doctor), reducing day-to-day operational friction. For content storage you choose between local disk or AWS S3; for emails, Resend is integrated. As the platform grows, you are responsible for database backups, PostgreSQL version upgrades, and ensuring the collab server scales horizontally if you have many concurrent editors — none of which is handled automatically.
Compared to a managed service, self-hosting means no SLA, no vendor-provided support contract (the community Discord and GitHub Issues are the primary channels), and no automatic failover. The official cloud-hosted LearnHouse offering handles infrastructure, automatic updates, and managed backups, and includes enterprise features without requiring a commercial license negotiation. For smaller teams or individual educators, the operational overhead of self-hosting may outweigh the cost savings; for institutions with existing DevOps capacity and data residency requirements, the trade-off often favors self-hosting.
Related Apps
strapi
CMS
Open-source headless CMS that auto-generates REST and GraphQL APIs from your content models, with a fully customizable admin panel you control.
strapi
OtherGhost
CMS · Blogging
Open source headless Node.js CMS for professional publishing, paid memberships, and newsletters with a fully owned audience.
Ghost
MITPayload CMS
Developer Tools · Blogging · CMS
The open-source, Next.js-native headless CMS that lives inside your /app folder and gives you a full TypeScript backend instantly.