How to install an IPA into an iOS device, e.g. for Ad Hoc distribution
Asked Answered
T

1

15

I have been trying to install an .ipa file into my physical iOS device using Ad Hoc distribution (without having to upload to App Store or TestFlight) but unfortunately I have been stuck with a few errors, for example: This app could not be installed because its integrity could not be verified.

enter image description here

Tham answered 28/8, 2021 at 21:39 Comment(5)
1. You need to have the device uuid in the provisioning profile. 2. Export the ad-hoc build 3. Plug your phone into your Mac. 4. Drag and drop the exported ipa onto the phone in the finder sidebar.Barbados
Dragging the ipa onto the iPhone on the sidebar doesn't actually work for me. I had to use the Apple Configurator app. Thanks for adding the other pre-requisitesTham
It does work, but you can't just drag it to the phone name in the sidebar as I suggested. You have to click on the phone in the sidebar so that the window is showing the phone details, then drag the IPA from another finder window into the phone details - The icon will get a green + and you can drop it to install.Barbados
Thanks! That's definitely easier than Apple Configurator 2Tham
I found one simple way to do this, refer my answer herePrebend
T
33

Took me a while to find this out. There were a lot of references to using iTunes, which is no longer available, and no references to using Finder, or alternatively Apple Configurator 2.

Prerequisites:

  • Your device is added to your provisioning profile. This is automatically done by Xcode when you select the device and build the app onto the device.
  • Plug your device in
  • Archive the application (create the .xcarchive): Select the target device (e.g. arm64/ a physical iPhone 12) and archive the app: Product > Archive
  • In the Organizers window, click Distribute App, and select Ad Hoc. Continue with the defaults options or customise to your liking. This should create a folder containing a .ipa file.
  • As of iOS 16, you might need to enable Developer Mode in settings.

Main steps:

As Paulw11 said in the comments, you can do this in Finder. Select the device in Finder and drag the .ipa file onto the device details.

enter image description here

More complicated alternative:

  • Install Apple Configurator 2. Drag the .ipa file found in the exported directory in finder (exported from Xcode) onto the iOS screen inside the Apple Configurator 2 window, and the iOS app will be installed:

enter image description here

Finally, you should see this step, and the application will be available on your home screen.

Command line: As How to install an ipa/app file into iPhone with command line? states, if you have Apple Configuration 2 installed, you can open it and click "Apple Configurator 2" on Menu Bar, and install Automation tools. Then, cfgutil is available to you,

  • so you can run: cfgutil install-app ipa-file.ipa

enter image description here

Tham answered 28/8, 2021 at 21:39 Comment(3)
Thank you for demonstrating the Apple Configurator way! All of the other answers to this topic show the old deprecated way of doing it using iTunes. Your answer is a saviour :)Sudarium
Hello, can we install using adhoc without plugging the phone to the computer?Hedgehog
Hi @eskemender, yes this should be possible using the Finder-drag approach if you configure wireless sync: support.apple.com/en-gb/guide/mac-help/mchlada1d602/mac. I haven't tried it myself. Not sure if it's possible via Apple Configurator though.Tham

© 2022 - 2024 — McMap. All rights reserved.