iOS shares a kernel and most frameworks with macOS, but lives under far stricter rules: every app is sandboxed, every binary is signed, every install goes through Apple. That tradeoff — less freedom for developers, fewer footguns for users — is why iPhone is the platform people pay for and developers ship to first.
← Back to Foundations| Layer | What It Does |
|---|---|
| XNU kernel | Same Mach + BSD hybrid as macOS. Process scheduling, memory, syscalls. |
| Core OS | Bionic-style libc, dyld linker, security daemons, kernel extensions. |
| Core Services | Foundation, Core Data, CloudKit, Network framework, Grand Central Dispatch. |
| Media | Core Animation, Core Graphics, Metal, AVFoundation. |
| Cocoa Touch | UIKit — the touch-first app framework. SwiftUI sits beside it. |
| Apps | Sandboxed, signed, distributed via Apple. |
The kernel will not execute unsigned code. Every binary — app, framework, dylib — must be signed by an Apple-issued certificate. This blocks an entire class of attacks where malware drops a payload to disk and runs it.
Every app runs as its own user with access only to its container directory. To touch the camera, microphone, photos, contacts, or location, the app must declare an entitlement and the user must approve a runtime prompt. Background access is further gated.
A separate coprocessor with its own OS (sepOS), holding biometric data, keychain keys, and Apple Pay tokens. Even a fully-rooted main OS can't extract secrets from it. Face ID / Touch ID never leave the enclave.
Every submission is reviewed before reaching the store. Inconsistent in practice, but it filters obvious malware and policy violations. Combined with kill-switch revocation, Apple can yank a malicious app from every device in hours.
| Tool / Framework | Role |
|---|---|
| Swift | The modern primary language. Strongly typed, ARC-managed, value-type-friendly. |
| Objective-C | Legacy but still pervasive — UIKit's history is here. Bridges seamlessly with Swift. |
| Xcode | The only supported IDE. Includes simulators, Instruments, code signing, App Store submission. |
| SwiftUI | Declarative UI shared across iOS, macOS, watchOS, tvOS, visionOS. |
| UIKit | Imperative UI framework. Still used heavily for complex apps and animations. |
| TestFlight | Beta-distribution service for staged rollouts. |
| CloudKit | Apple-hosted backend for storing user data without running servers. |