Running React Native apps on specific iOS simulators

By Perttu Lähteenlahti

··2 min read
Running React Native apps on specific iOS simulators

If you're developing React Native apps for iOS you're most likely familiar with this command:

react-native run-ios

In most cases that command opens up the iPhone X simulator. Instead, if you want to open your React Native app in a specific simulator you can also add the wanted device name with the simulator flag like this:

react-native run-ios simulator='iPhone 8'

And it will open up the iPhone 8 Simulator. You can get the full list of available devices with the command

xcrun simctl list devices

And here's a list of all the available devices available for testing:

react-native run-ios --simulator="iPhone 5s"
react-native run-ios --simulator="iPhone 6"
react-native run-ios --simulator="iPhone 6 Plus"
react-native run-ios --simulator="iPhone 6s"
react-native run-ios --simulator="iPhone 6s Plus"
react-native run-ios --simulator="iPhone 7"
react-native run-ios --simulator="iPhone 7 Plus"
react-native run-ios --simulator="iPhone 8"
react-native run-ios --simulator="iPhone 8 Plus"
react-native run-ios --simulator="iPhone SE"
react-native run-ios --simulator="iPhone X"
react-native run-ios --simulator="iPhone XR"
react-native run-ios --simulator="iPhone XS"
react-native run-ios --simulator="iPhone XS Max"
react-native run-ios --simulator="iPhone 11"
react-native run-ios --simulator="iPhone 11 Pro"
react-native run-ios --simulator="iPhone 11 Pro Max"
react-native run-ios --simulator="iPhone XS Max"
react-native run-ios --simulator="iPad Air"
react-native run-ios --simulator="iPad Air 2"
react-native run-ios --simulator="iPad"
react-native run-ios --simulator="iPad Pro"
react-native run-ios --simulator="iPad"

I'm getting "Could not find iPhone X simulator" or similar error message when running this command

At times you might run into problems with this command. This error message, for example, is quite common:

Could not find iPhone X simulator

Error: Could not find iPhone X simulator

This often caused by updating to a new Xcode version which doesn't include the iPhone X simulator any more, which is the default for react-native-cli. This problem should disappear when you pass the simulator flag and another device than iPhone X.

This was a quick and simple guide to running on different iOS simulators when building React Native apps. I wrote this because I found myself googling different device names too often. I hope that you find it useful 🙂

Perttu Lähteenlahti

Written by

Perttu Lähteenlahti

Developer Advocate at RevenueCat

Get the next article straight to your inbox

React Native Recap — Perttu's biweekly newsletter with tutorials, curated links, and what's worth paying attention to in the ecosystem.

Free, every two weeks. Unsubscribe in one click.

Related Articles

Getting Started with React Native in Finland

Getting Started with React Native in Finland

·4 min read

Your complete guide to starting React Native development in Finland. Learn about the community, resources, meetups, and how to connect with Finnish RN developers.

P

Perttu Lähteenlahti

Expo vs Bare React Native: Which Should You Choose?

Expo vs Bare React Native: Which Should You Choose?

·7 min read

A comprehensive comparison of Expo and bare React Native. Learn when to use each approach, the trade-offs involved, and how to make the right choice for your project.

P

Perttu Lähteenlahti