Virtualization
Create virtual machines and run macOS and Linux-based operating systems.
Mentioned in
Overview
The Virtualization framework provides high-level APIs for creating and managing virtual machines (VM) on Apple silicon and Intel-based Mac computers. Use this framework to boot and run macOS or Linux-based operating systems in custom environments that you define. The framework supports the Virtual I/O Device (VIRTIO) specification, which defines standard interfaces for many device types, including network, socket, serial port, storage, entropy, and memory-balloon devices.
To set up a VM, configure a VZVirtualMachineConfiguration. If you’re creating a macOS guest also configure a VZMacPlatformConfiguration, and then add the devices you want to expose to the guest operating system. Then, create a VZVirtualMachineConfiguration object with your configuration data, and use that VM object to start, pause, and resume the VM environment. To interact with the guest, you create a VZVirtualMachineView with the VZVirtualMachine object to display and interact with the graphical content in a window.
Topics
Essentials
Adding the Virtualization Entitlement to Your Projectcom.apple.security.virtualizationUsing iCloud with macOS virtual machines
Virtual machine setup
Running macOS in a virtual machine on Apple siliconRunning Linux in a Virtual MachineRunning GUI Linux in a virtual machine on a MacInstalling macOS on a Virtual MachineCreating and Running a Linux Virtual MachineVirtualize macOS on a MacVirtualize Linux on a MacRunning Intel Binaries in Linux VMsAccelerating the performance of Rosetta
Runtime
Devices
AudioGraphicsKeyboards and pointing devicesMemoryNetworkRandomizationSerial portsShared directoriesSocketsStorageConsolesClipboard sharingUSB DevicesCustom Virtio drivers