If you’re using a new Apple Silicon Mac (M1 / M2 / M3) and need to install macOS on an older Intel Mac, Apple makes this surprisingly difficult — sometimes impossible — using official tools.
Older macOS versions are distributed as .pkg installers, but:
- They don’t produce a bootable USB on modern Macs
createinstallmediaoften fails or isn’t accessible- The installer app can’t be launched on Apple Silicon
This script exists to solve that exact problem.
It takes an official macOS installer .pkg, extracts it correctly, and creates a bootable USB installer that works on Intel Macs, even when created on Apple Silicon.
Use this script if:
- You only have access to a modern Apple Silicon Mac
- You need to reinstall macOS on an older Intel Mac
- Internet Recovery doesn’t work or isn’t available
- The macOS installer you downloaded is a
.pkg, not an app
The script automates a process that normally requires undocumented manual steps:
- Extracts the hidden Install macOS.app from Apple’s
.pkg - Mounts the required disk images
- Runs Apple’s own
createinstallmediain a way that still works on modern macOS - Produces a properly bootable USB installer for Intel Macs
- macOS (Apple Silicon or Intel)
- USB drive (8 GB minimum, 16 GB recommended)
- Official macOS installer
.pkg - Administrator (sudo) access
Legacy macOS installers can be downloaded from Apple:
https://support.apple.com/102662
git clone https://github.com/Raasu2/macOS-BootableUSB-Builder.git
cd macOS-BootableUSB-Builderchmod +x create_bootable_installer.shNote the volume name (example: InstallUSB).
./create_bootable_installer.shYou’ll be asked for:
- The full path to the macOS installer
.pkg - The USB volume name
The script handles the rest.
- Insert the USB into the Intel Mac
- Power on and hold Option (⌥)
- Select the installer and proceed normally
- The script only erases the USB volume you specify
- Temporary files are cleaned up automatically
- Double-check the USB name before confirming
This script is based on real recovery steps discussed here:
https://apple.stackexchange.com/questions/418100/create-an-el-capitan-rescue-usb-using-a-modern-m1-mac
The manual method works — this script makes it repeatable and less error-prone.
MIT License