Open-source project
react-cosmos/react-cosmos avatar
react-cosmos/react-cosmos

React Cosmos: a component sandbox whose GitHub page points everything to reactcosmos.org

Sandbox for developing and testing UI components in isolation

8,699 stars381 forksTypeScriptMIT

At a glance

What is it?
React Cosmos is an MIT-licensed TypeScript monorepo for developing and testing UI components in isolation, released as v7.4.1 on 2026-08-31. The repository is easy to read as a codebase, but setup and usage live on reactcosmos.org, so evaluating it starts with the live demo and the getting started guides.
Who is it for?
React Cosmos fits a React team that wants to build and check components outside the full application, uses Vite, webpack or Next.js, and is comfortable taking its setup instructions from reactcosmos.org rather than the repository. It is a poor pick for anyone who needs the decision made from the GitHub page alone, since the README carries no install steps or comparison with other tools.
Can I use it commercially?
Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 4 days ago.
What is it written in?
Mainly TypeScript, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 22, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • react-cosmos/react-cosmos8,699 ★ · +14
Star history
Repository2026-09-222026-11-22
react-cosmos/react-cosmos8.7k8.7k

14 Stars in the last 61 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

The GitHub README is a signpost, and the manual lives on reactcosmos.org

React Cosmos describes itself in one line: a sandbox for developing and testing UI components in isolation. The README on GitHub adds very little to that. It sends readers to a set of getting started guides at reactcosmos.org/docs/getting-started, to the full documentation at reactcosmos.org/docs, and to a live demo at reactcosmos.org/demo/. There is no install command, no configuration example and no screenshot walkthrough in the README itself.

For a reader deciding whether to adopt it, this has a practical cost. Everything about how components are registered, how the sandbox is started and what the configuration file looks like has to be read on the documentation site, which is a separate thing to keep in sync with the version you install. The package is published to npm as react-cosmos, the name linked from the npm badge at the top of the README. If you pin a version, check that the docs page you are following matches it.

Separate entry points for Vite, webpack and Next.js

The README speaks of guides in the plural, and the repository backs that up. The examples/ directory contains vite/, webpack/, todo/ and shared/, and the root package.json lists examples/* as npm workspaces next to packages/*. The bundler you use decides which guide applies, and the Vite and webpack examples are working projects inside the same repository you can read alongside the guide.

Next.js gets its own callout. The README singles out a Next.js integration as the place to start for React Server Components. That is the only framework named in the README, and the only place server components are mentioned. A team on another framework, or one that renders server components without Next.js, has to check the documentation site for its setup before assuming it is covered, because neither the README nor the example folder names one.

A Lerna monorepo with a separate next tag for prereleases

The root package.json is marked private and is never published. Publishing goes through Lerna, with a lerna.json at the top level. The release script first runs release:check, which clears the build, builds, links source entries, lints, links dist entries and runs the test suite once, and only then calls lerna publish with a commit message of the form "[release] %s".

A second script, release:next, runs the same check and then publishes with --dist-tag=next --exact. For users, the consequence is simple: prerelease builds of React Cosmos go to the next tag on npm rather than to latest, so a plain install picks up the stable line, and trying a prerelease means asking for the next tag explicitly. The two helper scripts link-entries src and link-entries dist switch the workspace between source and built output, which matters if you clone the repository to debug a problem against the package code.

Release history through 2026 and the state of the main branch

Three releases appear in 2026. v7.3.0 shipped on 2026-04-17, v7.4.0 on 2026-08-17 and v7.4.1 on 2026-08-31. The last push to the main branch was on 2026-10-30, so the repository is receiving commits after the latest release. Anyone reading main on GitHub is reading code newer than the published v7.4.1 package, and should compare against the v7.4.1 tag when tracking down a bug report.

The project is MIT licensed, which puts no conditions on using it inside a commercial codebase beyond keeping the licence notice. The README asks for sponsorship through GitHub Sponsors under the ovidiuch account, to support continued development. Questions go to GitHub Discussions or the React Cosmos Discord, and a Code of Conduct in .github/ applies to all community channels.

Vitest, Playwright and Oxc tooling inside the workspace

The package.json scripts show how the project checks itself. Unit tests run through Vitest with vitest.config.js, and coverage comes from @vitest/coverage-v8 feeding a Codecov badge. End-to-end tests run with Playwright, using playwright.config.ts at the root, and test:e2e:ui opens Playwright's interactive mode. Type checking is plain tsc under check-types. Formatting and linting use oxfmt and oxlint, configured by .oxfmtrc.json and .oxlintrc.json at the root.

The development dependencies hint at what the sandbox touches. Type packages for express, ws, webpack-hot-middleware and pem sit next to @types/react 19.2.18 and @types/react-dom 19.2.4, and the toolchain includes esbuild-loader and css-loader. A contributor needs to be comfortable in that stack. A user who only installs react-cosmos does not see any of it, but should know the workspace is typed against React 19 packages when reading its source.

Nothing on the GitHub page settles the choice against other sandboxes

Readers who arrive comparing React Cosmos with Storybook, Ladle or React Styleguidist will not find that comparison on the GitHub page. The README makes no claims about other tools, lists no feature table and gives no numbers for startup time or bundle size. That leaves the reader to form a view from the demo and the docs rather than from the project's own pitch.

The consequence is that a team cannot rule React Cosmos in or out from the repository alone. The fastest way to an answer is the live demo at reactcosmos.org/demo/, followed by the getting started guide for the bundler already in your project. If your criteria include a particular addon, a documentation mode or visual regression testing, look for it in the docs explicitly, because the README is silent on all three.

Agent instructions and plans checked in at the root

The repository root carries AGENTS.md and CLAUDE.md, along with .agents/ and .claude/ directories and a plans/ folder. These sit beside the usual CONTRIBUTING.md in .github/, which the README names as the starting point for contributors.

For an outside contributor, these files are worth reading before opening a pull request, since AGENTS.md and CLAUDE.md are, by their names, addressed to coding agents working on the codebase. They do not change anything for someone using the published package. They do mean a clone of the repository includes more than source and tests, and the plans/ folder is part of the tracked tree.

Editorial conclusion

React Cosmos fits a React team that wants to build and check components outside the full application, uses Vite, webpack or Next.js, and is comfortable taking its setup instructions from reactcosmos.org rather than the repository. It is a poor pick for anyone who needs the decision made from the GitHub page alone, since the README carries no install steps or comparison with other tools. Before adopting it, open reactcosmos.org/demo/ and follow the getting started guide for your own bundler on a branch of your project.

Frequently asked questions

What is React Cosmos used for?

React Cosmos is a sandbox for developing and testing UI components in isolation. A live demo runs at reactcosmos.org/demo/.

How do I install React Cosmos?

The React Cosmos README points to getting started guides at reactcosmos.org/docs/getting-started, one per setup, with a separate Next.js integration for React Server Components. The package is published to npm as react-cosmos.

What is the latest React Cosmos release?

The latest React Cosmos release is v7.4.1, published on 2026-08-31, after v7.4.0 on 2026-08-17. The main branch received its last push on 2026-10-30.

What licence does React Cosmos use?

React Cosmos is released under the MIT licence, both in the LICENSE file and in the root package.json.

Official sources

  1. License: MIT
  2. Project website
  3. react-cosmos/react-cosmos on GitHub
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/react-cosmos-react-cosmos.svg)](https://hysenlabs.com/projects/react-cosmos-react-cosmos)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/react-cosmos-react-cosmos.svg)](https://hysenlabs.com/projects/react-cosmos-react-cosmos)

Was this useful?