Look iOS Developer, No Mac Required – Build an iOS Application using Xamarin and Visual Studio for Windows without using a Mac

If you’re a die-hard Windows user, like me, you’ll be excited to know that you can now build iOS application using Xamarin (and Xamarin.Forms) and Visual Studio, without having to buy or use a Mac. That’s right for development, you no longer need to invest, or carry around, a Mac. In this post I’ll walk you through how to enable this feature.

If you’re a die-hard Windows user, like me, you’ll be excited to know that you can now build iOS application using Xamarin (and Xamarin.Forms) and Visual Studio, without having to buy or use a Mac. That’s right for development, you no longer need to invest, or carry around, a Mac. In this post I’ll walk you through how to enable this feature.

I’m working in the latest preview of Visual Studio 2019 and as of now, to use Xamarin Hot Restart (the feature that powers the no Mac development experience), you need to check the Enable Xamarin Hot Restart option under Preview Features in the Tools, Options dialog.

After enabling Xamarin Hot Restart, make sure you restart Visual Studio. Next, set your iOS project to be the startup project by right-clicking the iOS project in Solution Explorer, followed by the Set as Startup Project menu item.

Make sure in the toolbar the option next to the play button says Local Device. Click the play button, which will kick off the Setup Hot Restart experience.

There are a couple of steps to jump through the first time you want to use Hot Restart. Make sure you follow the instructions to avoid having to redo steps.

The first step in the process it to Download iTunes – make sure you click the Download iTunes button. Do NOT install iTunes from the Microsoft Store. If you’ve done this previously, make sure you uninstall it, and then install it by clicking the Download iTunes button.

Clicking the Download iTunes button will open your default browser but it will attempt to immediately download the file – make sure you check out the downloads so you can launch the file once it’s downloaded.

Step through the iTunes installer.

Once iTunes is installed the Setup Hot Restart process will detect the presence of iTunes (note that it will not detect iTunes if you’re installed it from the Microsoft Store).

Next, make sure you have an iOS device plugged in and that you’ve clicked the Trust option on the device when prompted to trust the connected computer. The Setup Hot Restart process should detect the attached device.

Next, sign into your Apple Developer account.

And select the Development Team you want to use for provisioning.

After completing the Setup Hot Restart process you should see that the build process will continue and that in the Output window you’ll see the iPA being created and subsequently pushed to the device.

When prompted, you’ll need to launch the installed application on the iOS device – this manual step is required in order for Visual Studio to attach the debugger.

And there you have it – you now have an iOS application being debugged using Visual Studio on an actual device with no Mac required!!!

20 thoughts on “Look iOS Developer, No Mac Required – Build an iOS Application using Xamarin and Visual Studio for Windows without using a Mac”

  1. Thanks for the tutorial. I could run my app on my iOS Device, but when I get the message “Connecting Debugger”, even opening the App, I can not debug and the app is being closed. Did you face with this problem? Thanks.

  2. Provided that I cannot provision automatically (I need to pass the Entitlements.plist configuration file to the process which is only possible on manuel provisioning), how can I use Hot Restart to still work on Windows?

    When trying, I get the following error message:
    No valid iOS code signing keys found in keychain. Please enable Automatic Provisioning from the iOS Bundle Signing page.

    When using a network-connected Mac, Visual Studio pulls information such as codesigning key and provisioning profile from the Mac. Now with Hot Restart, I guess, it expects the information locally and cannot find it.

    Does it even work?

  3. Great article Nick!
    Is there any way to do this with a free Apple Dev Account?! I mean I stuck at the provisioning section “Select Team Page”. I just start learning and I don’t want to pay 99$/y at least right now. I tried hello world with Xcode and it worked with my free dev account. Is there a way to do that with HotRestart too?

  4. It worked, and it is such a good surprise: thanks a lot to the Xamarin team and to you for having pointed me in the right direction!
    The funny thing is that a prior version of iTunes downloaded from the MS Store is required to connect the iPad during the Hot Restart setup, and that the iTunes uninstall and reinstall steps you mention are not required: excellent :-)!

    1. Interesting – I tried with the Store version initially (didn’t read the instructions properly!!) and the setup process didn’t detect the presence of the Store version so I couldn’t proceed. Glad you got it to work

    1. I understand that this would reduce a cost, but the reality is that you should be doing a final round of testing on a real device for all apps.

  5. Everything seemed to go well following these steps. But Deploying fails with the following error:

    “An error occurred while trying to deploy the app ‘App1.iOS.app’. Details: Error running winiosterminal: ‘An error occurred while deploying the application ‘App1.iOS.app’ into ‘brendan’s iPhone’. Details: An Afc error occurred. The error code was ObjectNotFound’. Command: ‘deploy -u=383dff3c9a96a1414278e25cef7f83deec5fa825 -i=com.bzsoftware.app1 -n=app1.iOS.app'”

    The “App1” iOS app works well otherwise if I Build and Distribute it via the AppCenter and install it on the same iPhone 8 device.
    SysInfo: Visual Studio 2019 16.5.1, Windows 10, iPhone 8, iOS 13.3.1

  6. Nick,
    Tried setting up the above, but my system doesn’t see a local device, only options are ‘Remote device’ and ‘Simulator’. Tried uninstalling and reinstalling iTunes and various other tips various posts have directed me to, yet I don’t see the local device option. Thoughts?

  7. Hi,
    is it possible to use an free Apple Developper account to only run and test iOS apps in Xamarin?

  8. Wonderful! This is one of the most delightful things that I’ve learned this year! Being able to develop IOS/IPhone apps in Visual studio without Mac is a game changer.

    P.S: To Whom was not able to see “Local Device”: Local Device became visible when I select “Mobile.App (Xamarin.Forms)” project template to create the project. I had tried to create IOS Only Xamarin Project first and didn’t see the “Local Device”.

  9. Yep. He is right. It is paid unfortunately 99 USD per year. Well I dunno which one worth more. The Mac cloud ones or this one :/

Leave a Reply

Your email address will not be published. Required fields are marked *