Set up iPhone & iPad
This guide covers compiling and installing D2R Mobile onto iPhone or iPad using Xcode on macOS or pre-built shells via sideloading. It explains build flags for iOS 26+ versus iOS 18–25, transferring the 18 resource files, and first-launch shader behavior.
Overview
Running D2R Mobile on iOS requires two parts:
1. Application Package (.ipa or Xcode build): The compiled binary containing the patched execution runtime, Metal graphics translation layer, and touch controls.
2. Game Resources: The 18 .data archive files extracted from RomFS/data of your legally owned Switch release (version 1.0.34.0 / 3.3.94012), totaling roughly 5.6 GB.
Depending on your operating system and available hardware, choose between Method 1 (Xcode on Mac) or Method 2 (No-Xcode Sideloading).
Method 1: Building with Xcode on Mac (Canonical Route)
This route compiles the host, translates shaders on the computer, and installs directly to your device via Apple development tools.
1. Environment & Setup
Ensure your game files are placed in your workspace (~/dm-work/data/switch/3.3.94012/Update/ containing ExeFS and RomFS):
git clone https://github.com/d2r-mobile/d2r-mobile.git
cd d2r-mobile
./setup.sh check
When ./setup.sh check confirms game files are ready, run ./setup.sh to initialize the workspace and Python environment. Activate the environment:
source ~/dm-work/build/cache/dm/venv/bin/activate
2. Configure Local Credentials
Copy the example configuration and set your Developer Team ID and chosen Bundle ID:
cp dm/ios/local.env.example dm/ios/local.env
Edit dm/ios/local.env:
- DM_TEAM_ID: Your 10-character Apple Developer Team ID.
- DM_BUNDLE_ID: A unique reverse-DNS identifier (e.g. com.yourname.d2rmobile).
- DM_DEVICE: The device identifier from xcrun devicectl list devices (required for command-line installation).
3. Build & Install
Run run.sh from dm/ios:
cd dm/ios
# For iOS 26 or later (default Metal 4 pipeline):
./run.sh build
# For iOS 18.0 through iOS 25.x (older Metal compatibility pipeline):
DM_IOS_M3=1 ./run.sh build
(Note for A16 and earlier chips: Generate the ASTC texture pack first using dm/tools/astc_pack.py and pass DM_ASTC_PACK="/path/to/pack" during build).
To install to your connected device:
./run.sh install
Alternatively, open the generated project dm/ios/DmIOS.xcodeproj (created automatically by XcodeGen during run.sh build) in Xcode, select your connected device, and choose Product > Run (Cmd + R).
Method 2: Sideloading via No-Xcode Shell
If building on Windows, Linux, or without an Xcode development environment, assemble the package using an official pre-built shell.
1. Obtain the Matching Shell
Download the appropriate shell archive from the upstream repository Releases:
- D2RMobile-shell-build-input.zip: For devices running iOS 26 or later.
- D2RMobile-shell-ios18-build-input.zip: For devices running iOS 18 through iOS 25.
2. Package Game Files into the Shell
Run d2rm_pack.py with positional arguments:
python3 dm/tools/d2rm_pack.py <shell.zip> <game_files_directory> <output.ipa>
<shell.zip>: The path to the downloaded shell zip.<game_files_directory>: The directory containingExeFS/andRomFS/.<output.ipa>: Output file path.
(For A16 and earlier devices, set the environment variable D2RM_ASTC_PACK to your generated pack path before running d2rm_pack.py).
3. Sideload the IPA
- Connect your iPhone or iPad to your computer.
- Follow Sideloadly’s official instructions to sign and install the generated IPA. AltStore Classic is another documented provisioning route; exact compatibility with this app can vary. Upstream lists several alternative signing tools as unverified, so do not assume all of them work.
- On your device, go to Settings > General > VPN & Device Management and tap Trust under Developer App.
- If running iOS 16 or newer, ensure Developer Mode is enabled under Settings > Privacy & Security > Developer Mode (requires a reboot).
Transferring Game Resources onto the Device
Upon launching, the app requires the 18 .data files from RomFS/data (approximately 5.6 GB):
Option A: Using the iOS Files App or Finder
- Place all 18
.datafiles into a single folder. - Transfer the folder into the app container:
- Files App (On-device): Copy the folder to Files > On My iPhone (or On My iPad) > D2R Mobile.
- Finder (USB): Select your device in Finder, click the Files tab, find D2R Mobile, and drop the folder in.
- Path Flexibility: Upstream searches the app container and detects any folder directly containing the 18
.datafiles (up to 4 directory levels deep). - Community Workflow Note: If you use community cloud builds (such as
jiayx/d2r-mobile-build), the resource archive unpacks into a folder namedD2R Mobile Resources. Place that entire folder directly insideD2R Mobile. - Legacy Devices (A14–A16): Copy the
Legacy Device Packfolder alongside the resource folder at the same level.
Option B: Automated devicectl Push (Mac Developers)
If your device is connected via USB and configured with Xcode:
xcrun devicectl device copy to --device <device identifier> \
--domain-type appDataContainer --domain-identifier <bundle ID> \
--source ~/dm-work/data/switch/3.3.94012/Update/RomFS \
--destination 'Library/Application Support/romfs'
Return to the app and tap Retry. The screen lists the detected files and confirms when all 18 archives are present.
First Launch & Shader Compilation
- Packages built with Xcode (Mac): Shaders are compiled into Metal libraries during build time. The app launches immediately into the game menus with no compilation delay.
- Packages built without Apple's shader compiler (Windows/Linux no-Xcode): On first launch, the app displays \"First launch: preparing shaders\" with a progress bar, compiling all 7212 shaders on the phone. Upstream reports approximately 7 minutes on iPhone 17 Pro Max; other devices and builds can differ. The device will become warm.
- Interrupting compilation: You can switch away or close the app safely. When reopened, previously compiled shaders are verified from cache in less than a millisecond, effectively resuming progress.
Operational Notes
- Save sync: A build needs valid iCloud container entitlements for automatic sync. Free personal signing does not provide them; use the local
Documents/savefolder and manual backups. A paid developer configuration still needs correct provisioning and should not be assumed to sync automatically. - Performance Expectations: Upstream test reports indicate playable frame rates on supported SoCs, but frame rates are not guaranteed and depend on thermal constraints. Figures cited reflect upstream test logs rather than independent site benchmarks.
Frequently Asked Questions
Does first launch always take 7 minutes to prepare shaders?
No. Packages compiled via Xcode on a Mac include precompiled Metal shader libraries and boot directly to the main menu. Packages produced without Apple's shader compiler (such as the Windows no-Xcode route) require on-device shader preparation; upstream reports about 7 minutes on one tested phone, not a universal time. You may safely switch apps or close the game during compilation; it resumes quickly from cached shaders.
Do I need a paid Apple Developer account to install?
No. A standard free Apple ID works for both Xcode installation and sideloading utilities. Note that free personal certificates expire every 7 days per Apple policy, requiring periodic re-signing.
How should game resource files be named and placed?
Upstream searches the app Documents directory and accepts any folder directly containing the 18 .data files (up to 4 directory levels deep). In community automated CI builds (such as the jiayx build workflow), this folder is conventionally named 'D2R Mobile Resources'.