Similarly to Swift apps, WatchKit apps are not properly bundled for iTunes Connect distribution by command line tools. Unfortunately, only Xcode itself (Xcode.app) creates the necessary directories containing the runtime dependencies that iTunes Connect requires for WatchKit apps.
This issue would manifest in an Invalid Binary state for your app in iTunes Connect, and the following email from Apple.
We have discovered one or more issues with your recent delivery for “MyWatchKitApp”. To process your delivery, the following issues must be corrected:
Invalid WatchKit Support - The bundle contains an invalid implementation of WatchKit. The app may have been built or signed with non-compliant or pre-release tools. Visit developer.apple.com for more information.
Once these issues have been corrected, you can then redeliver the corrected binary.
The App Store team
Fortunately, there is a very simple workaround. Like Swift, WatchKit apps require a top-level directory in the
.ipa. In this case, the directory is named
The contents of this directory are simple, a single binary from within Xcode.app named
WK. The exact path to this binary within Xcode.app is as follows:
Start by unzipping your .ipa file and creating the
$ unzip MyApp.ipa $ rm MyApp.ipa $ mkdir WatchKitSupport
Then, copy the
WK binary into the
$ cp /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/Library/Application Support/WatchKit/WK WatchKitSupport
All thats left to do is to re-package your
$ zip -r MyApp.ipa .
Your command-line built app is now ready for deployment to iTunes Connect!
We’ve completely automated this process at Ship.io. We offer continuous integration and delivery for iOS and Android apps that’s super simple to set up. We’re free to try out, so feel free to take a look!