React-scripts isn’t on your PATH; reinstall dependencies, then run npm start inside the project folder.
You’re trying to start a Create React App project and Windows throws the error: react-scripts can’t be found. It’s annoying because your code might be OK. The problem is your setup, your folder, or your install.
This guide walks you through fixes that work on real projects: missing node_modules, a half-installed dependency tree, the wrong Node version, and mixed package managers. Follow the steps. Most people are back to a running dev server fast.
What The Error Means In Plain Terms
react-scripts is a package that ships the dev server, build tools, and test runner used by Create React App. When you run npm start, npm looks in your project’s dependencies and tries to execute the script that calls react-scripts.
If Windows says it “is not recognized,” it’s telling you the executable isn’t available where the command is being run. That can happen when the dependency isn’t installed, when you’re not in the right project folder, or when the install exists but got corrupted.
You’ll see the same message if you try to run react-scripts start directly from a terminal that isn’t inside the project, because global access isn’t the normal path for this tool.
React-Scripts Is Not Recognized As An Internal Or External Command On Windows
On Windows, this error tends to come from one of a small set of causes. The fastest way to fix it is to confirm basics first, then move into a clean reinstall if needed.
Confirm You’re In The Right Folder
Open the terminal inside your project root. That’s the folder that has package.json. If you run commands from a parent folder, npm can’t find your scripts and it may fall back to confusing errors.
- Print your current path — Run
cdin Command Prompt orpwdin PowerShell, then confirm it matches your project directory. - List project files — Run
dir(Command Prompt) orls(PowerShell) and check thatpackage.jsonis present. - Start via npm — Run
npm startfrom that same folder instead of callingreact-scriptsdirectly.
Check That React-Scripts Is Installed Locally
If react-scripts isn’t listed as a dependency, or it never installed, the command won’t exist inside node_modules.
- Search in package.json — Open
package.jsonand look for"react-scripts"underdependencies. - Inspect node_modules — Check for
node_modules/react-scriptsandnode_modules/.binin your project. - Reinstall react-scripts — Run
npm i react-scriptsif it’s missing, then trynpm startagain.
Run A Clean Install When The Tree Is Broken
A partially completed install can leave the project in a state where some packages exist, but the executable links in .bin do not. A clean install resets that.
- Close running dev servers — Stop any terminal sessions that might be holding files open.
- Delete node_modules — Remove the
node_modulesfolder from the project root. - Delete the lock file — Remove
package-lock.jsonfor npm, oryarn.lockfor Yarn, orpnpm-lock.yamlfor pnpm. - Install again — Run
npm install, then runnpm start.
If you’re seeing react-scripts is not recognized as an internal or external command after a clean install, move on to the next checks. It usually means the command is being blocked, or Node and npm are out of sync.
Quick Checks That Catch The Weird Cases
Some setups look normal until you hit one detail that breaks the script runner. These checks are quick, and they save you from repeating installs.
Check Node And npm Are Installed Correctly
Create React App expects a modern Node version. If Node is missing, or if your terminal is pointing at an older install, installs can fail silently or scripts can behave oddly.
- Check Node version — Run
node -vand confirm it’s a maintained release line for your team. - Check npm version — Run
npm -vand make sure it matches the Node install you’re using. - Restart your terminal — Close and reopen the terminal so PATH updates take effect.
Spot A Failed Install Before You Reinstall Again
If installs finish fast but the folder still looks wrong, pause and read the last 30 lines of the install output. Peer dep warnings are common. Errors about permissions, network timeouts, or integrity checks are the ones that matter.
- Run install with clean output — Use
npm installin a fresh terminal so you can see the failure line. - Search for error codes — Look for ERESOLVE, EINTEGRITY, EPERM, or ENOENT and fix that root issue first.
- Confirm react-scripts exists — After install, run
npm ls react-scriptsand confirm it shows a version, not “empty.”
Don’t Mix Package Managers In One Project
Using npm one day and Yarn the next can create a dependency tree that installs, but doesn’t match the scripts you expect. Pick one and stick with it for that repo.
| Package Manager | Install Command | Start Command |
|---|---|---|
| npm | npm install |
npm start |
| Yarn | yarn |
yarn start |
| pnpm | pnpm install |
pnpm start |
- Keep one lock file — Delete extra lock files so only the one for your chosen tool remains.
- Reinstall with your tool — Run the matching install command from the table above.
- Run scripts the same way — Use
npm start,yarn start, orpnpm start, not a mix.
Watch For A Broken Script Line
Open package.json and check the scripts section. For a standard Create React App project, start usually points to react-scripts start. If it was edited, the tool might be calling something that doesn’t exist.
- Compare the start script — It should look like
"start": "react-scripts start"in many setups. - Undo custom changes — If you see extra flags or a different command, revert and test again.
- Commit the fix — Save a clean script line so teammates don’t hit the same error.
Fixes That Work When Windows PATH And Shell Rules Get In The Way
Sometimes react-scripts is installed, but your shell can’t execute the shim in node_modules/.bin. Windows security settings, file path issues, and odd terminal behavior can trigger this.
Use The Project Script Instead Of Calling React-Scripts Directly
In most cases, you should not run react-scripts as a standalone command. Let npm resolve the local binary from your project.
- Run the start script — Use
npm start(or your manager’s equivalent) in the project root. - Try npx as a test — Run
npx react-scripts --versionto confirm the package can execute. - Prefer local installs — Avoid installing
react-scriptsglobally; it creates version mismatch pain later.
Shorten The Project Path If It’s Deep Or Has Odd Characters
Windows still trips on long paths in some tooling stacks. If your project lives inside a long chain of folders, move it closer to the drive root and retry.
- Move the repo — Put it in a short path like
C:\\dev\\my-app. - Reinstall dependencies — Delete
node_modulesand reinstall after the move. - Start again — Run
npm startand watch for a clean launch again.
Clear npm Cache When Installs Keep Failing
A bad cached tarball can keep reintroducing the same broken install. Clearing cache is a useful step when you see repeat install warnings or integrity errors.
- Review recent install errors — If you keep seeing integrity warnings, plan on clearing the npm cache.
- Clean the cache — Run
npm cache clean --forceif problems show up. - Install fresh — Run
npm installagain, then start the dev server.
Check For Files Being Locked By Sync Tools
OneDrive, Dropbox, and some backup tools can lock files mid-install. When that happens, npm may skip writing a file inside node_modules. You end up with a folder that exists, but missing command shims.
- Pause folder syncing — Stop syncing for the project folder while you reinstall.
- Move the repo locally — Put the project in a plain folder that is not being mirrored.
- Reinstall after the move — Delete
node_modulesand reinstall once the folder is stable.
Mac And Linux Notes If You See The Same Message
The exact wording “not recognized” is Windows-flavored, but the root causes are the same on macOS and Linux: the package is missing, the scripts are broken, or the install is incomplete.
- Confirm the folder — Run
lsand make surepackage.jsonis right there. - Reinstall dependencies — Delete
node_modulesand your lock file, then runnpm install. - Check permissions — If you see EACCES errors, fix your Node install method instead of using
sudowith npm.
If you use nvm, set the Node version for the project and reinstall. It prevents odd mismatches when your shell loads a different Node build than you expect.
Prevent The Error From Coming Back On The Next Pull
Once you fix it, lock the habits that keep the repo stable. Most repeats happen after switching branches, pulling changes, or cloning on a new machine.
Make Installs Repeatable For The Team
Keep your lock file committed. It helps teammates install the same dependency versions and reduces “works on my machine” issues.
- Commit the lock file — Keep
package-lock.json,yarn.lock, orpnpm-lock.yamlin version control. - Use clean install in CI — Prefer
npm ciin continuous integration because it matches the lock file exactly. - Document the Node version — Add an
.nvmrcor mention the version in your README.
Use A Single Command Set For Team Scripts
If your repo has helper scripts in the README, keep them consistent. Mixing commands like npm start in one place and yarn start in another nudges people into a mixed install without noticing.
- Pick one manager per repo — If the lock file is
package-lock.json, stick with npm. - Update docs and snippets — Replace old commands in the README and onboarding notes.
- Add a quick guard — A small preinstall script can warn when the wrong manager is used.
Know When To Migrate Away From React-Scripts
Create React App still powers many apps, but some teams move to Vite or Next.js for faster tooling and easier upgrades. If your project is often blocked by tooling issues, a planned migration can reduce rebuild pain.
- Check your app’s needs — If you rely on CRA defaults and rarely touch config, staying put is fine.
- Test a branch migration — Create a branch, scaffold Vite or Next.js, then port one route and build step.
- Move with a checklist — Keep tests passing, keep the same env vars, and validate builds before switching main.
If you hit the error again, come back to the top and repeat the quick checks. In most cases, the fix is still the same: confirm the folder, reinstall cleanly, then run scripts through npm. That’s the reliable path out of react-scripts is not recognized as an internal or external command.
