React Native: Rename the project. Do’s and Don’ts

So most common and also the toughest question is can we rename the existing react native project? A simple answer is YES YOU CAN. There are many RIGHT ways to achieve this. but if you miss some minor details then the mistake cost goes very high. You need to follow any method listed right below.

Image for post
Image for post


You can change the name attribute in package.json, run react-native upgrade, and just let react overwrite the android/ios files. Don't overwrite your index files if there is unsaved code, however.

Then change your Appregistry line from

AppRegistry.registerComponent('MyAppIOS', () => MyAppIOS);


AppRegistry.registerComponent('MyApp', () => MyApp);


What simply works for me several times is instructed below;

  • First copy the directory in which your to-be-name-changed application exists. And go to your newly cloned directory.
  • Change the name at index.ios/android.js file which is given as a parameter to AppRegistry.
  • Change the name and version accordingly on package.json
  • delete /ios and /android folders which are remaining from your older app as well as the app.json file if you have.
  • run $react-native upgrade to generate /ios and /android folders again.
  • run $react-native link for any external dependency.
  • finally, run $react-native run-ios or anything you want.

Method-3 [Onlt For Android]

The way I did this for android (hacky, but it works) is just changed the string app_name field in


It will change the name of your installed android app to whatever you put as the value. After this change re-run the app.

Now the time comes what you need to take care or YOU SHOULD NOT DO


You might also hear about the npm package (react-native-rename):


react-native-rename < newName >

It works fine but……it will ruin your project. Never use this

Hope this helps someday! ❤

Written by

🤠 Internet Cowboy | 💻 JS Aficionado |

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store