How to Install Redux Toolkit

Learn how to install the Redux toolkit in a local project.

How to install Redux toolkit

If working on your local machine, you can’t truly get started with RTK without having it installed in your project.

It’s a good thing installing the Redux toolkit is pretty straightforward.

If you’re creating a new app, use create-react-app with the redux template:

npx create-react-app my-app --template redux

By default, the Redux template sets up a RTK project.

If you want to add the Redux toolkit to an existing app, install via npm or yarn and use the following:

## NPM
npm install @reduxjs/toolkit

## Yarn
yarn add @reduxjs/toolkit

And that’s it! You’ve got RTK installed and ready to go.

Get hands-on with 1300+ tech skills courses.