Getting Error 404 while running npm install create-react-app
16,321
Solution 1
First check if is a Proxy Issue.
Try to install the package with another internet connection!
Another causes
Missing repository registry
$ npm set registry https://registry.npmjs.org/
Clean cache
$ npm cache clean
$ npm rebuild
Solution 2
My problem also same but when I try following commands then works fine
If you've previously installed create-react-app
globally via npm install -g create-react-app
, I recommend you uninstall the package using npm uninstall -g create-react-app
to ensure that npx always uses the latest version.
Then reinstall using
npm install -g create-react-app
Author by
Vivek Futane
Updated on June 27, 2022Comments
-
Vivek Futane almost 2 years
Getting error
404
while runningnpm install create-react-app
ornpm install -g npm@latest
.Log:
0 info it worked if it ends with ok 1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe', 1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js', 1 verbose cli 'install', 1 verbose cli 'create-react-app' ] 2 info using [email protected] 3 info using [email protected] 4 verbose npm-session 1f3eafc1b2f09e93 5 silly install loadCurrentTree 6 silly install readLocalPackageData 7 http fetch GET 404 http://registry.npmjs.org/create-react-app 66ms 8 silly fetchPackageMetaData error for create-react-app@latest 404 Not Found: create-react-app@latest 9 verbose stack Error: 404 Not Found: create-react-app@latest 9 verbose stack at fetch.then.res (C:\Program Files\nodejs\node_modules\npm\node_modules\pacote\lib\fetchers\registry\fetch.js:42:19) 9 verbose stack at tryCatcher (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\util.js:16:23) 9 verbose stack at Promise._settlePromiseFromHandler (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:512:31) 9 verbose stack at Promise._settlePromise (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:569:18) 9 verbose stack at Promise._settlePromise0 (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:614:10) 9 verbose stack at Promise._settlePromises (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\promise.js:693:18) 9 verbose stack at Async._drainQueue (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\async.js:133:16) 9 verbose stack at Async._drainQueues (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\async.js:143:10) 9 verbose stack at Immediate.Async.drainQueues (C:\Program Files\nodejs\node_modules\npm\node_modules\bluebird\js\release\async.js:17:14) 9 verbose stack at runCallback (timers.js:810:20) 9 verbose stack at tryOnImmediate (timers.js:768:5) 9 verbose stack at processImmediate [as _immediateCallback] (timers.js:745:5) 10 verbose cwd M:\Projects\TestApps\ReactApp 11 verbose Windows_NT 6.1.7601 12 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "create-react-app" 13 verbose node v8.11.3 14 verbose npm v5.6.0 15 error code E404 16 error 404 Not Found: create-react-app@latest 17 verbose exit [ 1, true ]
-
Vivek Futane over 5 yearsThanks for quick response. But I am getting bellow error - npm ERR! code E404 npm ERR! 404 Not Found: npm@latest
-
Eugenio Valeiras over 5 yearsCan you try with other internet net? So we discard the chance of firewall configuration??
-
Vivek Futane over 5 yearsThanks Eugenio. It was proxy issue. I updated proxy and registry now its working. :)
-
Eugenio Valeiras over 5 yearsGood to help! I modified my answer so you can mark as approved and help other people :)
-
Eugenio Valeiras over 5 years@VivekFutane Was this the solution??
-
Vivek Futane over 5 yearsyest, but now I am getting new error while starting npm - npm ERR! missing script: start
-
Eugenio Valeiras over 5 yearsThat means that you are not in the folder where the package.json is!
-
Eugenio Valeiras over 5 yearsCan you add to your post your package json if you are in the correct place?