Flutter: how to change app name on iOS
Name of Flutter project not always (or almost never) match name that we want to display on user device. So we need to change default name for application. That’s easy! There is article with detailed description and screenshots in official documentation. But, there is a catch. It’s doesn’t work.
Disclaimer. I’m must be mistaken. Documentation is clear and probably I’ll do something wrong. And I’ll be appreciate if you can correct me in the comments.
What happens?
When I did change Display Name in Xcode project that’s what happens:
- name of app file is changing;
- PRODUCT_NAME is changing.
As result of this changes:
- no changes in the application name on iPhone;
- after clean Android Studio fails to run app on iPhone: “Could not find the built application bundle at build/ios/iphonesimulator/Runner.app”.
This is not what I want.
What to do?
So, reset all previous changes and don’t touch Display Name.
Go to the Xcode project folder and open Info.plist for edit (in Xcode you can choose Open As > Source Code in file context menu). All we need is edit value for key CFBundleName. It’s a user-visible short name for the bundle.
There are two another useful keys that you can add: CFBundleDisplayName and CFBundleSpokenName. With CFBundleDisplayName you can set the user-visible name for the bundle, used by Siri and visible on the iOS Home screen (it’s equals to CFBundleName by default). And CFBundleSpokenName will be used as a replacement for the app name in text-to-speech operations. See Apple documentation on this.
Thanks for reading! I’ll really be appreciate any feedback.