Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

In Xcode, how can I register a device to test on it, without having a paid Apple Developer account?

I am trying to test an app in a real device, using XCode 9.

In Xcode > General > "Automatically manage signing" I get this error: Failed to create provisioning profile. There are no devices registered in your account on the developer website. Plug in and select a device to have Xcode register it.

I have tried physically plugging in an iPod, an iPad and an iPhone. They all show up in iTunes, and also in XCode under Windows > "Devices and Simulators", but XCode simply doesn't register anything.

I also tried to go to the website to register the devices manually, but it seems I cannot even access this website without having a paid Apple developer account?

I do NOT have a paid Apple developer account, but I do have the Apple ID. I know that I can test in a real device without an account because in this page https://developer.apple.com/support/compare-memberships/ under Benefits and Resources the Sign in with Apple ID column has Test on Device checked.

Please, how can I solve this?

like image 637
MarcG Avatar asked Aug 06 '18 04:08

MarcG


2 Answers

At the top of the Xcode window, from left to right, after the Run and the Stop buttons, there is another button which displays the tooltip "Set the active scheme" when you hover the mouse over it.

This button lets you choose a simulator. But once your device is plugged in it also let you select that device. Once you select your device, the problem disappears.

Note to those using Xcode to run code developed for Google's Flutter: You probably must also select Product > Run in Xcode, before you are able to go the device to trust the certificate, under the device's General > Device Management.

like image 128
MarcG Avatar answered Sep 28 '22 10:09

MarcG


What I normally do when I test on a device is by selecting general device before I archive the build, and then after you follow the prompts after the build, choose install on a device.

If you are really set on just being able to run directly without archiving, make sure that you are signed in with your apple id (the only reason you would need to pay would be if you are submitting to the app store, so you don't have to worry about that) under accounts (XCode -> Preferences -> Accounts), and then replug your device.

And if that doesn't work, try following the instructions on this site: https://help.apple.com/developer-account/#/ under Registera Single Device.

like image 38
Hikari Avatar answered Sep 28 '22 09:09

Hikari