How to Master React: The Complete 2027 Roadmap
Learn React from your first component to Server Components, the React Compiler, performance and testing: a staged path with time estimates, projects, comparisons and verified free resources.
Last reviewed: December 2026 (React 19.3 is the latest release; React Compiler 1.0 is stable)
If you want to learn React in 2026 or 2027, the official docs are excellent, but the ecosystem around them is noisy: frameworks, state libraries, styling systems and data-fetching tools all compete. This roadmap tells you what to learn in what order, what to skip, and what a React expert actually knows. It assumes no prior React knowledge but some HTML, CSS and JavaScript.
Paid resources are marked (paid). Everything else is free.
Table of contents
- The roadmap at a glance
- Stage 0: JavaScript you need first
- Stage 1: Thinking in React
- Stage 2: State, effects and data
- Stage 3: TypeScript, tooling and testing
- Stage 4: Routing, frameworks and Server Components
- Stage 5: The ecosystem (state, data, styling, forms)
- Stage 6: Performance and the React Compiler
- Stage 7: Mastery
- React hooks reference card
- What’s new in React 19 through 19.3
- Frameworks compared
- Best courses and books
- Projects to build
- Common mistakes
- Interview preparation
- FAQ
- Where to go next
- Contributing
The roadmap at a glance
| Stage | Focus | Time estimate | You can… |
|---|---|---|---|
| 0 | Modern JavaScript, DOM, async | 2-4 weeks | Write ES modules, use map/filter, async/await, destructuring |
| 1 | Components, JSX, props, state, lists, events | 2-3 weeks | Build interactive UIs from a design |
| 2 | Effects, refs, context, reducers, custom hooks | 2-3 weeks | Explain when you do not need an effect |
| 3 | TypeScript, Vite, ESLint, testing | 2-3 weeks | Ship a typed, tested app |
| 4 | Routing, a framework, Server Components, Actions | 3-4 weeks | Build a full-stack app with Next.js or React Router |
| 5 | Server-state libraries, client state, styling, forms, accessibility | 3-4 weeks | Choose libraries with reasons |
| 6 | Rendering model, profiling, the Compiler, Suspense, transitions | 2-3 weeks | Find and fix a real performance problem |
| 7 | Architecture, design systems, internals, React Native | ongoing | Lead React architecture on a team |
Total: roughly 4-6 months from zero to job-ready at 10 hours per week, given basic JavaScript.
Stage 0: JavaScript you need first
Time: 2-4 weeks. Most React confusion is JavaScript confusion. Make sure these feel natural:
let/const, arrow functions, template literals- Destructuring, spread and rest (
{...obj},[...arr]) - Array methods:
map,filter,reduce,find,some,toSorted - Immutability: updating objects and arrays without mutating them
- Modules:
import/export, default vs named exports - Promises,
async/await,fetch, error handling - Closures (the cause of most “stale state” bugs)
- Truthy/falsy and
&&/??(used constantly for conditional rendering) - The DOM and events at a basic level
| Resource | Type |
|---|---|
| javascript.info | Free, the best modern JS tutorial |
| MDN JavaScript Guide | Free reference |
| Eloquent JavaScript, 4th ed. by Marijn Haverbeke | Free book, author-hosted |
| You Don’t Know JS Yet by Kyle Simpson | Free on GitHub |
Stage 1: Thinking in React
Time: 2-3 weeks.
Concepts in order
- Components are functions that return JSX. Name them in PascalCase.
- JSX rules: one root (or a Fragment),
className, curly braces for expressions. - Props pass data down; they are read-only.
- Conditional rendering and lists with keys (stable IDs, not array indexes when items can reorder).
- Events and state with
useState. Setting state schedules a re-render with a new snapshot. - Purity: components must be pure functions of props, state and context during render.
- Lifting state up and one-way data flow.
- Controlled inputs.
Best resource
The official react.dev Learn section is the best React course that exists, and it is free. Do every challenge at the end of each page. In order:
- Quick Start
- Tutorial: Tic-Tac-Toe
- Thinking in React
- Describing the UI
- Adding Interactivity
- Managing State
Exercise: Build a filterable product table from a JSON array (the “Thinking in React” example), then add sorting, a “favourites” toggle and a cart total without looking at the solution.
Stage 2: State, effects and data
Time: 2-3 weeks. This is the stage that separates people who “use React” from people who understand it.
Topics
| Topic | Key idea |
|---|---|
| State structure | Avoid redundant and duplicated state; derive values during render |
useReducer |
Centralise complex update logic |
| Context | Pass data deeply without prop drilling; not a state manager by itself |
Refs (useRef) |
Values that persist without causing re-renders; DOM access |
Effects (useEffect) |
Synchronise with external systems only (network, subscriptions, DOM APIs) |
| Cleanup | Every subscription or timer an effect starts, it must stop |
| Custom hooks | Reuse stateful logic, not state itself |
useEffectEvent |
Read latest values inside effects without re-running them |
The most important page in the docs
You Might Not Need an Effect. Most bugs in beginner and intermediate React code come from effects used to compute derived state, reset state on prop change, or chain updates. Read it twice.
Also read: Synchronizing with Effects, Lifecycle of Reactive Effects, Reusing Logic with Custom Hooks.
Data fetching, honestly
Fetching in useEffect works for learning but has race conditions, no caching and waterfalls. In real apps use a framework’s data loading (Stage 4) or a server-state library such as TanStack Query (Stage 5). Learn the raw version once so you understand what those tools solve.
Exercise: Build a search-as-you-type component against a public API (for example the Open Library Search API). Handle loading, errors, race conditions (ignore stale responses) and debouncing. Then rewrite it with TanStack Query and compare.
Stage 3: TypeScript, tooling and testing
Time: 2-3 weeks.
Tooling
| Need | Best pick | Notes |
|---|---|---|
| Build tool (no framework) | Vite | Fast dev server; npm create vite@latest |
| Linting | ESLint with eslint-plugin-react-hooks | The hooks plugin catches rules-of-hooks bugs and Compiler-incompatible code |
| Formatting | Prettier | Or Biome for lint + format in one fast tool |
| Package manager | npm, pnpm | pnpm is faster and stricter |
Create React App is deprecated (the React team sunset it in February 2025). Do not start new projects with it.
TypeScript with React
- Type props with a
typeorinterface; children asReact.ReactNode. - Type events (
React.ChangeEvent<HTMLInputElement>) and refs (useRef<HTMLDivElement>(null)). - Use discriminated unions for component state (
{ status: 'loading' } | { status: 'error'; error: Error } | ...). - Generic components (
<List<T>>).
| Resource | Type |
|---|---|
| Using TypeScript (react.dev) | Free, official |
| React TypeScript Cheatsheets | Free community reference |
| TypeScript Handbook | Free, official |
| Total TypeScript | Free tutorials + (paid) workshops |
Testing
| Layer | Tool | What to test |
|---|---|---|
| Unit / component | Vitest + React Testing Library | Behaviour from the user’s perspective, not implementation details |
| API mocking | Mock Service Worker | Network at the boundary, shared between tests and dev |
| End-to-end | Playwright | Critical user flows in real browsers |
| Visual / component workshop | Storybook | Component states in isolation |
Read Common mistakes with React Testing Library and query by role (getByRole) first; it doubles as an accessibility check.
Stage 4: Routing, frameworks and Server Components
Time: 3-4 weeks.
The React team recommends starting new apps with a framework (Creating a React App). Their current recommendations are Next.js (App Router), React Router (framework mode) and Expo for native apps, with TanStack Start and RedwoodSDK listed as up-and-coming. Building from scratch with Vite, Parcel or Rsbuild is documented too.
Concepts
- Client-side routing and nested layouts.
- Rendering strategies: client-side rendering (CSR), server-side rendering (SSR), static generation (SSG), streaming.
- React Server Components (RSC): components that run only on the server, can be
async, can read data directly, and send no JavaScript for themselves. Client Components are marked with'use client'. - Server Functions (
'use server') called from the client, often via forms. - Actions:
<form action={fn}>,useActionState,useFormStatus,useOptimistic. - Suspense for streaming and loading states;
use()to read promises and context. - Hydration and why mismatches happen.
Resources
| Resource | Type |
|---|---|
| Next.js Learn course | Free, official, builds a dashboard app |
| Next.js docs | Free, official |
| React Router docs | Free, official |
| TanStack Start | Free, official |
| Server Components reference | Free, official |
| Server Functions reference | Free, official |
Security note: in December 2025 the React team disclosed critical vulnerabilities in React Server Components packages, followed by fixes. Keep react, react-dom and your framework on patched versions, subscribe to the React blog, and treat Server Functions as public HTTP endpoints: validate input and check authorisation inside every one.
Exercise: Build a notes app with Next.js or React Router: list and detail routes, server-side data loading, a create form using Actions with optimistic updates, and error/loading boundaries.
Stage 5: The ecosystem (state, data, styling, forms)
Time: 3-4 weeks. Learn one good option per category, and why it exists.
State management
Split state into kinds and pick tools per kind:
| Kind of state | Best pick | Alternatives | When to avoid a library |
|---|---|---|---|
| Server state (fetched data) | TanStack Query | SWR, RTK Query, framework loaders | If your framework’s loaders/RSC already cover it |
| Global client state | Zustand | Redux Toolkit, Jotai, MobX | Small apps: useState + context is enough |
| Complex app state with strict patterns | Redux Toolkit | Teams that want conventions and devtools | |
| Atomic, fine-grained | Jotai | ||
| URL state (filters, tabs, pagination) | The router’s search params, or nuqs | Always consider the URL first for shareable state | |
| Form state | React Hook Form | TanStack Form, native Actions | Simple forms: native <form> + Actions |
In the State of React 2025 survey, TanStack Query was the most-used library and Zustand was second, and roughly a third of respondents used no dedicated state library at all.
Styling
| Approach | Example | Notes |
|---|---|---|
| Utility-first CSS | Tailwind CSS | Most popular choice in new projects |
| Copy-in components | shadcn/ui | Components you own, built on Radix/Base UI and Tailwind |
| CSS Modules | built into Vite/Next | Zero-runtime, scoped CSS |
| Headless primitives | Radix Primitives, React Aria, Base UI | Accessible behaviour, you style |
| Component libraries | MUI, Mantine, Chakra UI | Fast for dashboards and internal tools |
Runtime CSS-in-JS (styled-components, Emotion) works poorly with Server Components; prefer zero-runtime options in new RSC apps.
Validation, animation and more
- Schema validation: Zod or Valibot, shared between client and server.
- Animation: Motion (formerly Framer Motion), or React’s own
<ViewTransition>(Stage 6). - Tables and virtualisation: TanStack Table, TanStack Virtual.
- Internationalisation: react-intl (FormatJS) or i18next.
Accessibility
Use semantic HTML first, label every input, manage focus in dialogs, and test with a keyboard and a screen reader. References: MDN Accessibility, WAI-ARIA Authoring Practices Guide.
Stage 6: Performance and the React Compiler
Time: 2-3 weeks.
The rendering model
- Trigger (state change) → render (call components) → commit (update the DOM).
- A component re-renders when its state changes, its parent re-renders, or a context it reads changes.
- Re-rendering is usually cheap. Slow apps are usually caused by expensive renders, huge lists, or network waterfalls.
Read: Render and Commit, State as a Snapshot, Preserving and Resetting State.
The React Compiler
React Compiler (v1.0 stable since October 2025) is a build-time tool that automatically memoises components and values. With it, most manual useMemo, useCallback and React.memo become unnecessary. It requires code that follows the Rules of React; the ESLint hooks plugin reports code it cannot optimise. Learn manual memoisation once so you understand what it automates, then let the Compiler do it.
Concurrent features
useTransition/startTransitionmark updates as non-urgent, keeping input responsive.useDeferredValuelags a value behind so expensive children do not block typing.<Suspense>shows fallbacks while code or data loads.<Activity>keeps hidden UI’s state (and can pre-render it) without showing it.<ViewTransition>(stable in React 19.3) animates transitions with the browser View Transition API.
Tools
- React Developer Tools Profiler and “highlight updates”.
- Chrome DevTools Performance panel, which includes React-specific tracks in recent React versions.
- web.dev Core Web Vitals for real-user metrics (LCP, INP, CLS).
- Bundle analysis with your bundler’s analyser plugin.
Exercise: Render a 10,000-row table with filtering. Measure with the Profiler and INP in DevTools. Fix it with virtualisation, useDeferredValue, and the Compiler, measuring after each step.
Stage 7: Mastery
- Architecture: feature-based folder structure, boundaries between server and client code, error boundaries strategy, design systems and component APIs (compound components, polymorphic components, headless hooks).
- Internals: Fiber, reconciliation, lanes and scheduling. Read the React source on GitHub and the React Working Group discussions.
- Build your own React: the Build your own React walkthrough by Rodrigo Pombo rebuilds a mini React from scratch.
- React Native: reuse your React skills on iOS and Android with Expo.
- Libraries: publish a small component library with proper types, tests, accessibility and documentation.
- Stay current: the React blog, This Week In React newsletter, and React Conf talks on the React YouTube channel.
React hooks reference card
| Hook | Use for | Common pitfall |
|---|---|---|
useState |
Local state | Mutating objects instead of replacing them |
useReducer |
Complex state transitions | Putting side effects in the reducer |
useContext |
Reading context | Huge context values causing wide re-renders |
useRef |
Mutable value / DOM node | Reading ref.current during render |
useEffect |
Syncing with external systems | Using it for derived state |
useLayoutEffect |
Measure DOM before paint | Overuse blocks painting |
useMemo / useCallback |
Manual memoisation | Mostly unnecessary with the Compiler |
useTransition |
Non-urgent updates | Expecting it to speed up the work itself |
useDeferredValue |
Lagging an expensive value | |
useId |
Stable IDs for accessibility attributes | Using it for list keys |
useSyncExternalStore |
Subscribing to external stores | |
useActionState |
State driven by an Action (forms) | |
useFormStatus (react-dom) |
Pending state of a parent form | Must be called in a child of the <form> |
useOptimistic |
Optimistic UI during an Action | |
useEffectEvent |
Non-reactive logic inside effects | Calling it outside effects |
use |
Read a promise or context, can be conditional | Creating the promise during render on the client |
Full reference: react.dev/reference/react.
What’s new in React 19 through 19.3
| Version | Date | Highlights |
|---|---|---|
| React 19 | Dec 2024 | Actions, useActionState, useOptimistic, use, Server Components/Functions stable, ref as a prop, <Context> as provider, document metadata, stylesheet and preload APIs |
| React 19.2 | Oct 2025 | <Activity>, useEffectEvent, cacheSignal, Performance Tracks in Chrome DevTools, partial pre-rendering APIs |
| React Compiler 1.0 | Oct 2025 | Stable automatic memoisation |
| React Foundation | Feb 2026 | React and React Native now hosted by a foundation under the Linux Foundation |
| React 19.3 | Sep 2026 | Stable <ViewTransition> and addTransitionType, Fragment refs, browser() in react-dom to skip server rendering, Trusted Types support, rendering <Context> directly in Server Components |
Upgrading from React 18: follow the React 19 Upgrade Guide; codemods handle most changes (removed propTypes and defaultProps for function components, string refs, legacy context, ReactDOM.render).
Frameworks compared
| Next.js | React Router (framework mode) | TanStack Start | Expo | Vite SPA | |
|---|---|---|---|---|---|
| Maintainer | Vercel | Shopify | TanStack | Expo | Community |
| Server Components | Yes (App Router) | Supported | In progress / evolving | Experimental (Expo Router) | No |
| Data loading | RSC + fetch caching |
Loaders and actions | Server functions + TanStack Router loaders | Expo Router | You choose |
| Deploy | Anywhere Node runs; best integration on Vercel | Anywhere | Anywhere | App stores + web | Any static host |
| Best for | Full-stack apps, SEO, jobs | Web-standard full-stack apps, Remix users | Type-safe full-stack apps | iOS/Android/web | Dashboards, internal tools, SPAs |
Best pick to learn: Next.js, because it has the most job listings and the deepest RSC support. Learn React Router as well if you value web-standards loaders/actions or maintain existing SPA code.
Best courses and books
Free
| Resource | Notes |
|---|---|
| react.dev Learn | Best pick. Official, interactive, current |
| Next.js Learn | Official full-stack course |
| The Odin Project: React course | Free, project-based curriculum |
| Full Stack Open (University of Helsinki) | Free university course: React, Node, testing, TypeScript, GraphQL |
| freeCodeCamp | Free front-end libraries certification |
| Scrimba: Learn React | Free interactive screencasts (Pro is (paid)) |
| patterns.dev | Free book-style site on React and rendering patterns |
Paid
| Resource | Notes |
|---|---|
| The Joy of React by Josh W. Comeau (paid) | Deep, beautifully explained, project-based |
| Epic React by Kent C. Dodds (paid) | Advanced workshops: hooks, patterns, performance, testing |
| Frontend Masters React courses (paid) | Many instructors, intermediate to advanced |
| Learning React, 2nd ed. by Alex Banks and Eve Porcello (paid) | Book; predates React 19, good for fundamentals |
| Fluent React by Tejas Kumar (paid) | Book on how React works internally |
Projects to build
- Tic-tac-toe with history (official tutorial), then add a board-size option.
- Todo app done properly: reducer,
localStoragesync via an effect, filters stored in the URL, tests with Testing Library. - Search UI against a public API with debouncing, race-condition handling, and TanStack Query.
- Multi-step form with React Hook Form + Zod validation and accessible error messages.
- Kanban board with drag and drop (for example dnd kit), keyboard support, optimistic updates.
- Full-stack app with Next.js or React Router: auth, database, Server Functions, streaming with Suspense, deployed.
- Dashboard with charts, a virtualised 10k-row table and a profiler-driven performance write-up.
- Design-system mini library: Button, Dialog, Tabs, Combobox on headless primitives, documented in Storybook, published to npm.
- Animated photo gallery using
<ViewTransition>with shared-element transitions. - Expo app sharing hooks and types with your web app.
Common mistakes
- Effects for everything. Derive values during render; respond to events in handlers.
- Mutating state (
arr.push,obj.x = 1) and wondering why nothing updates. - Index as key for lists that reorder or filter.
- Copying props into state and then wondering why it does not update.
- Defining components inside components, which remounts them every render and loses state.
- One giant context for the whole app.
- Global state for server data instead of a cache (TanStack Query, framework loaders).
- Premature memoisation everywhere instead of measuring (or using the Compiler).
- Div soup with click handlers instead of buttons and links.
- Trusting Server Functions’ callers. They are network endpoints; validate and authorise.
Interview preparation
Topics frequently reported in public front-end interview experiences:
- Virtual DOM and reconciliation, why keys matter
- State vs props, controlled vs uncontrolled inputs
- The dependency array and stale closures
- When to use
useMemo/useCallback, and what the Compiler changes - Server vs Client Components; SSR vs CSR vs SSG; hydration
- Context performance trade-offs
- Error boundaries
- Accessibility basics
- Machine-coding rounds: build an autocomplete, a modal, infinite scroll, a star rating, a data table, a nested comments tree
Practice: GreatFrontEnd (free questions + (paid) plans) and BFE.dev (free).
FAQ
How long does it take to learn React? With solid JavaScript, 4-8 weeks to be productive with the basics; 4-6 months to be job-ready including a framework, TypeScript and testing.
Should I learn JavaScript before React? Yes. At least the topics in Stage 0. React is mostly JavaScript.
Is React still worth learning in 2027? Yes. It remains the most-used front-end library by a wide margin in developer surveys and job listings, and it powers React Native for mobile.
Next.js or plain React? Learn React fundamentals with Vite or the official docs sandboxes, then learn Next.js (or React Router) for real apps. The React team recommends a framework for new projects.
Do I still need useMemo and useCallback?
Much less. With React Compiler enabled, most manual memoisation is unnecessary. Understand them for older codebases and interviews.
Redux or Zustand? For new projects, Zustand is simpler for most apps. Redux Toolkit is still a solid choice for large teams wanting strict conventions, and it is in many existing codebases.
Is Create React App dead? Yes, it was deprecated in February 2025. Use a framework or Vite.
Class components? Read-only knowledge. You will see them in older code; write function components.
Can I learn React for free? Yes. react.dev, Next.js Learn, Full Stack Open and The Odin Project are complete and free.
React vs Vue vs Svelte vs Angular? All are good. React has the biggest job market and ecosystem; Vue and Svelte are often considered simpler; Angular is common in large enterprises.
Where to go next
- TypeScript depth: the TypeScript Handbook.
- Mobile: Expo tutorial for React Native.
- Back end: Node.js, databases and auth, for example via Full Stack Open.
- Web platform: CSS layout, accessibility and performance on web.dev.
- Contribute: fix docs or issues in a library you use; the react.dev repo welcomes doc fixes.
Contributing
Corrections and improvements welcome.
- Open an issue for outdated APIs, broken links or missing topics.
- Pull requests: keep the stage order, mark paid resources (paid), no affiliate links, and explain in one line why a resource belongs.
If this helped you, a star helps others find it.
License
Content is licensed under CC BY 4.0. React is a trademark of its respective owners; this guide is independent.
More free resources
Part of the Ralpberry Labs open-source collection. See also Top 100 Open Source.