React Router

A multi-strategy router for React, from a lightweight library to a full SSR framework.

Framework
npm
v8.4.0
56,590 stars
MIT License

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum. How we score it →
95 /100 Excellent
Development Activity 100
Maintenance 96
Community 84
Maturity 60
Momentum 40

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation. How we score it →
89 /100 Excellent
Architecture 93
Code Quality 92
Innovation 90
Learning Curve 82

React Router is the routing layer originally built for single-page React apps, now maintained by Remix Software as a multi-strategy router: use it as a minimal library to add client-side navigation to any React app, or opt into full framework mode with @react-router/dev for file-based routes, server-side rendering, nested data loading, and code-splitting bundled into one Vite-powered toolchain.

With 56K+ GitHub stars, 46M+ weekly npm downloads, and an active release cadence spanning v6, v7, and v8, React Router underpins a large share of production React routing — from small SPAs pulling in just the react-router hooks and components to full-stack apps built entirely on its framework mode.

What You Get

  • The react-router package: hooks (useNavigate, useParams, useLoaderData) and components (<Routes>, <Link>, <Outlet>) for client-side routing in any React app.
  • @react-router/dev: a Vite plugin that turns React Router into a full framework — file-based routing, SSR, code splitting, and type-safe route modules.
  • @react-router/fs-routes, @react-router/node, @react-router/serve: framework-mode building blocks for filesystem route conventions, Node runtime adapters, and a production server.
  • create-react-router: a CLI scaffolder for bootstrapping new framework-mode projects from official templates.
  • Nested data loading and mutations via route loader/action functions, with automatic revalidation and pending-UI hooks (useNavigation, useFetcher).

Common Use Cases

  • Adding client-side navigation and nested layouts to an existing React SPA without adopting SSR.
  • Building a full-stack React app with server rendering, data loading, and mutations via framework mode.
  • Migrating a Remix application, since React Router v7 absorbed Remix’s framework runtime and APIs.
  • Implementing type-safe, file-based route trees with automatically generated route types.

Under The Hood

Architecture: The core router (packages/react-router/lib/router/router.ts, ~7,700 lines) implements a framework-agnostic state machine — createRouter and createStaticHandler — handling route matching, navigation, data loading, submissions, and error boundaries independent of React. A React bindings layer (components.tsx, hooks.tsx, context.ts) subscribes to this router’s state via context (DataRouterContext, DataRouterStateContext) and exposes the public hooks/components. DOM-specific bindings (lib/dom) layer on browser history integration, link prefetching, and target=_blank handling. Framework mode (@react-router/dev) sits atop the same core: it compiles file-based route conventions (@react-router/fs-routes) into the same RouteObject shape the router already understands, then wires a runtime adapter (@react-router/node, @react-router/serve, @react-router/express, @react-router/cloudflare) for SSR — meaning library and framework modes share one execution engine, differing only in entrypoints and build tooling.

Tech Stack: TypeScript throughout (98.9% of the codebase), organized as a pnpm workspace monorepo with 10 publishable packages under packages/. Builds run through tsdown (a Rolldown-based bundler) orchestrated by wireit for incremental caching, producing dual development/production builds with React Server Components-aware entrypoints. Framework mode is built on Vite 7 as its dev server and bundler. Peer dependencies require React >=19.2.7 and Node >=22.22.0, tracking the newest React release trains closely.

Code Quality: Extensive automated coverage — 143 test files under packages/react-router/tests alone, run with Jest (unit, via jest-environment-jsdom and @testing-library/react) plus a separate Playwright-driven integration suite (integration/) that exercises the framework build end-to-end. A repo-wide ESLint config enforces react-hooks, jsx-a11y, and TypeScript rules, paired with Prettier formatting. Module boundaries are consistent — router state (router/), React bindings (hooks.tsx, components.tsx, context.ts), and DOM-specific code (dom/) are cleanly separated, so the router core has no DOM or React dependency.

API Design: The public API is layered for progressive adoption: <BrowserRouter>/<Routes>/<Route> for the simplest declarative case, createBrowserRouter(routes) for data-router features, and file-based routes.ts conventions for framework mode — all compiling down to the same RouteObject shape, so moving between modes doesn’t require relearning concepts. Hook naming mirrors React idioms (useNavigate, useParams, useLoaderData, useFetcher), and TypeScript route-module types are generated from the route config so loader/action signatures are checked at compile time. Getting started in library mode is a single install plus a router provider; framework mode adds a Vite plugin and a routes.ts file, with create-react-router templates removing most of that boilerplate.

Used by 226 apps in this directory

TypeScript
98%
Apache 2.0

TinaCMS

CMS

13,811

An open-source, Git-backed headless CMS that gives editors a live visual editing UI over Markdown, MDX, JSON, and YAML content while developers keep everything in version control.

View details
92
Repo Health
74
Technical
59
Dependency
Built with
TypeScript 98%
Updated 1 weeks ago
TypeScript
56%
Other

Tolgee

Developer Tools

4,115

In-context localization platform that lets developers and translators edit app strings directly in the running application, with AI-powered machine translation and framework SDKs for React, Angular, Vue, and Svelte.

View details
90
Repo Health
84
Technical
65
Dependency
Built with
TypeScript 56%
Kotlin 43%
Updated 2 weeks ago
JavaScript
57%
AGPL 3.0

ToolJet

AI Agents · Low Code Platforms · No Code Platforms

41,007

Open-source AI-native platform to build and deploy internal tools, workflows, and AI agents with a visual drag-and-drop builder and 80+ data source integrations.

View details
94
Repo Health
81
Technical
63
Dependency
Built with
JavaScript 57%
TypeScript 36%
Updated 1 weeks ago
Go
93%
MIT

Traefik

Automation · Devops · Security

64,985

A cloud-native reverse proxy and load balancer that auto-configures itself from Docker, Kubernetes, and other orchestrators — zero manual routing required.

View details
93
Repo Health
85
Technical
64
Dependency
Built with
Go 93%
Updated 1 weeks ago
TypeScript
99%
Apache 2.0

Trigger.dev

AI Development · Automation · Developer Tools

16,427

Build and deploy fully-managed AI agents and background jobs in TypeScript — with no timeouts, durable retries, real-time observability, and elastic scaling built in.

View details
89
Repo Health
9
Technical
63
Dependency
Built with
TypeScript 99%
Updated 2 weeks ago
JavaScript
75%
AGPL 3.0

Twake Drive

Collaboration · File Storage

987

Open-source, self-hosted file manager with collaborative drives, AI-powered summarization, and OnlyOffice document editing for teams who want full data sovereignty.

View details
90
Repo Health
78
Technical
72
Dependency
Built with
JavaScript 75%
TypeScript 24%
Updated 2 weeks ago
JavaScript
75%
AGPL 3.0

Twake Drive

Collaboration · File Storage

987

Open-source, self-hosted file manager with collaborative drives, AI-powered summarization, and OnlyOffice document editing for teams who want full data sovereignty.

View details
90
Repo Health
78
Technical
72
Dependency
Built with
JavaScript 75%
TypeScript 24%
Updated 2 weeks ago
TypeScript
82%
Other

twenty

CRM

57,585

The open-source CRM you build, ship, and version like the rest of your stack — with customizable objects, AI agents, and a TypeScript SDK.

View details
92
Repo Health
82
Technical
64
Dependency
Built with
TypeScript 82%
MDX 15%
Updated 1 weeks ago
TypeScript
97%
Apache 2.0

Unleash

Ab Testing Experimentation · Developer Tools · Devops

13,836

The open-source feature management platform that lets you ship code to production and control who sees it — without redeploying.

View details
90
Repo Health
84
Technical
70
Dependency
Built with
TypeScript 97%
Updated 2 weeks ago

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers