Xcode: Failed to prepare device for development / iPhone is not available. Please reconnect the device
Xcode couldn’t set up the device — usually the device’s iOS version is newer than Xcode supports, Developer Mode is off, or pairing/trust is broken.
Failed to prepare device for developmentiPhone is not available. Please reconnect the deviceThis operation can fail if the version of the OS on the device is newerDeveloper Mode disabled Meaning
Each Xcode version supports iOS up to a certain release (needs device support files). iOS 16+ also requires Developer Mode enabled on the device.
Common causes
- Device iOS newer than this Xcode supports
- Developer Mode not enabled (iOS 16+)
- Device not trusted/paired
- Locked device or cable issues
⚡ Quick fix
- Update Xcode
- Enable Settings → Privacy & Security → Developer Mode and restart
- Unpair/re-pair (Devices and Simulators), trust the computer
Detailed fix by platform
Shell
- swift
xcrun devicectl list devices xcrun xctrace list devices
How to diagnose
- Versions — Xcode vs iOS version
- Developer Mode — On?
- Pairing — Trusted?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
- Cannot preview in this file SwiftUI Preview: Cannot preview in this file — the preview crashed / failed to build
- doesn't include the currently selected device Provisioning profile "x" doesn't include the currently selected device
- invalid active developer path xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun
Most viewed in iOS
Other ways to find it
Where this error sits
Origin: On your device. Errors that are often confused with or caused by this one (click to open):
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
💬 What worked for others
No tips yet — did something else fix this for you?
Share what worked for you
Tips are checked by an editor before they appear. Links are removed.
Report a correction or suggest an improvement
Last updated 14 Oct 2026