npm ERR! code ERR_SOCKET_TIMEOUT on creating new project using ng new appname

Your command cannot succeed, because npm fails to fetch some module due to internet connection problems.
You can try using different internet connection or increasing npm fetch timeouts.

I just had this issue and it helped changing timeouts:

npm config set fetch-retry-mintimeout 20000
npm config set fetch-retry-maxtimeout 120000

You can find default values running:

npm config ls -l

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)