Yarn - There appears to be trouble with your network connection. Retrying

t-doog picture t-doog · Jul 25, 2018 · Viewed 50.4k times · Source

I have been trying to do the quickstart guide for react native, but kept getting this error

There appears to be trouble with your network connection. Retrying...

My connection works just fine.

Answer

yacine benzmane picture yacine benzmane · Jul 25, 2018

This happens when your network is too slow or the package being installed is too large, and Yarn just assumes it's a network problem. Try increasing Yarn network timeout:

yarn add <yourPackage> --network-timeout 100000