First, securely transfer the generated .mobileconfig file to your iOS device, then import it
as an iOS profile. To transfer the file, you may use:
-
AirDrop, or
-
Upload to your device (any App folder) using
File Sharing, then open the "Files" App on your iOS device, move the uploaded file to the "On My iPhone" folder.
After that, tap the file and go to the "Settings" App to import, or
-
Host the file on a secure website of yours, then download and import it in Mobile Safari.
When finished, check to make sure "IKEv2 VPN" is listed under Settings -> General -> VPN & Device Management or
Profile(s).
To connect to the VPN:
-
Go to Settings -> VPN. Select the VPN connection with Your VPN Server IP (or DNS name).
-
Slide the VPN switch ON.
(Opional feature) Enable VPN On Demand to automatically start a VPN connection when your iOS device is on Wi-Fi.
To enable, tap the "i" icon on the right of the VPN connection, and enable Connect On Demand.
You can customize VPN On Demand rules to exclude certain Wi-Fi networks (such as your home network).
For more information, see the chapter "Guide: Customize IKEv2 VPN On Demand rules for macOS and iOS" in
📖 Book: Set Up Your Own IPsec VPN, OpenVPN and WireGuard Server.
Once connected, you can verify that your traffic is being routed properly by
looking up your IP address on Google.
It should say "Your public IP address is Your VPN Server IP".
If you get an error when trying to connect, see Troubleshooting.
To remove the IKEv2 VPN connection:
To remove the IKEv2 VPN connection, open Settings -> General -> VPN & Device Management or Profile(s)
and remove the IKEv2 VPN profile you added.