ReactNative Metro Bundler not starting automatically

Its because the port 8081 is in use..

Try

react-native start --port=8080

This will work out.


Replace the code with this one. The path of the file is -

node_modules\metro-config\src\defaults\blacklist.js

var sharedBlacklist = [
  /node_modules[\/\\]react[\/\\]dist[\/\\].*/,
  /website\/node_modules\/.*/,
  /heapCapture\/bundle\.js/,
  /.*\/__tests__\/.*/
];

I found this solution from Github.


Same exact problem I am facing too. I just updated to 0.59.1 and this isn't working... As a work around, I am running the metro builder in a separate tab, and then running react in a separate tab.

react-native start --reset-cache 

in one terminal and left it open

react-native run-android 

in another terminal


I tried following steps it resolves my issue

  1. Running packager on different port react-native start --port 8084 --reset-cache
  2. Run react-native run-android --port 8084 in second Command Prompt window.
  3. After error screen appear clicking Android Ctrl + M, iOS Command + D.
  4. Click Dev Settings button at the bottom.
  5. Click Debug server host & port for device button.
  6. Type localhost:8084 and click OK button.
  7. Again run react-native run-android --port 8084