Skip to main content

Installation

Redux Toolkit​

Redux Toolkit includes the Redux core, as well as other key packages we feel are essential for building Redux applications (such as Redux Thunk and Reselect).

It's available as a package on NPM for use with a module bundler or in a Node application:

# NPM
npm install @reduxjs/toolkit

# Yarn
yarn add @reduxjs/toolkit

The package includes a precompiled ESM build that can be used as a <script type="module"> tag directly in the browser.

Create a React Redux App​

The recommended way to start a new app with React and Redux is to use one of our official templates. These come with Redux Toolkit and React-Redux already configured for that build tool, and include a small example app that shows how to use several of Redux Toolkit's features.

Use a tool like tiged to clone and extract a template:

# Vite + TypeScript
npx tiged reduxjs/redux-templates/packages/vite-template-redux my-app

# Expo + TypeScript
npx tiged reduxjs/redux-templates/packages/expo-template-redux-typescript my-app

# React Native + TypeScript
npx tiged reduxjs/redux-templates/packages/react-native-template-redux-typescript my-app

# Standalone Redux Toolkit app structure example
npx tiged reduxjs/redux-templates/packages/rtk-app-structure-example my-app

For Next.js, use Next's with-redux example and see our Redux with Next.js guide:

npx create-next-app --example with-redux my-app

Complementary Packages​

React-Redux​

Most likely, you'll also need the react-redux bindings for use with React

npm install react-redux

Note that unlike Redux itself, many packages in the Redux ecosystem don't provide UMD builds, so we recommend using module bundlers like Vite and Webpack for the most comfortable development experience.

Redux DevTools Extension​

Redux Toolkit's configureStore automatically sets up integration with the Redux DevTools. You'll want to install the browser extensions to view the store state and actions:

If you're using React, you'll want the React DevTools extension as well:

Redux Core​

Redux Toolkit already includes and re-exports the redux core package, so most apps do not need to install it separately. To install the redux core package by itself:

# NPM
npm install redux

# Yarn
yarn add redux

If you're not using a bundler, you can access these files on unpkg, download them, or point your package manager to them.