Error after installing Realm: Must first create RPC session with a valid host

There might be a better answer in the future or not at all. So, here's what I found.

I'm not really sure what solves this issue. At least, make sure that realm's port (8082 by default) is reachable on your device by commanding adb forward tcp:8082 tcp:8082 in a terminal.

Furthermore, make sure the device is connected(!) to the same subnet/network to avoid any packet dropping.

Try completely removing the app from the device (reset) in combination with shutting down the packager and re-running react-native run-android / running from xcode.

I don't believe there is a uniform solution yet at the time of writing.