How to Install GSI ROM on ANY Android Device w/ Project Treble & Unlocked Bootloader! [TWRP Method]

For those of you who want to install Project Treble GSI(Generic System Image) ROM on your Android device with unlocked bootloader, you can use TWRP recovery to install them.  The process is actually not entirely different from flashing a regular custom ROM in TWRP, the only difference is that you will be using “Install from image” option instead of the default “Install from zip” option.  (If you don’t know what Project Treble is, please see “What is Project Treble for Android”.

What are GSI ROMs?

GSI or Generic System Image ROMs are basically “generic” custom ROMs you can flash on any Project Treble compatible Android device with unlocked bootloader.   There are two main methods of flashing these GSI ROMs.  One is to use fastboot commands using your computer connected to your Android device and the other is by using TWRP recovery.  Since TWRP recovery is much easier method, today I will be showing you how to flash GSI ROMs using TWRP.

Check if your Android device supports Project Treble and Find Out A or AB

You can only flash GSI ROMs to Android devices that have full Project Treble compatibility.  You can check this by installing the Treble Check app.

MAKE SURE you have unlocked your bootloader on your Android device.  You can refer to our Android Root 101 page on how to unlock your bootloader on any Android.

You should see a green checkmark that will tell you if your Android device is compatible with Project Treble or not.

Also you will be able to tell if your device support A or AB type.  Make a note of this and remember it as you will need it later.

Step 1. First, go ahead and download the GSI ROM you want to use, here’s a quick list of a few available out right now:

  • Pixel Experience Android 9.0 Pie GSI ROM – Link
  • AOSP Android 9.0 Pie GSI ROM – Link
  • Resurrection Remix GSI ROM Android 8.1 Oreo – Link
  • AOKP GSI ROM Android 8.1 Oreo – Link

You can also Google any GSI ROM you may want to flash.

For this tutorial, I will be using Pixel Experience GSI ROM, and I highly recommend it for those of you who want to try Android 9.0 Pie today.

On the download page, you will usually see a few different variations arm/arm64 or A/AB.  Most devices that support Project Treble are newer Android devices and most likely arm64.  And you can go ahead and download A or AB type depending on the response you received earlier with the Treble Check app.

Once downloaded, make sure the file ends in “.img” as most of these GSI ROMs are compressed in ZIP or XZ format.  If compressed in ZIP or XZ format, you can uncompress/extract the actual image file.(For XZ format, use 7ZIP to extract or Alzip app).

You will most likely need Gapps for these GSI ROMs, so also download the appropriate Gapps, you can try Android 9.0 Pie Gapps or Android 8.1 Oreo Gapps.

If you want to also root your Android, also download latest Magisk ZIP Installer, Magisk uninstaller(just in case things go wrong), and Magisk Manager APK.

You should download/copy all these files to your Android device.

Step 2. Reboot into TWRP by powering off and doing the buttons.  For most Android devices, you can do Volume Down + Power button to enter into bootloader menu then select “Recovery” and power button to enter TWRP recovery.  For Samsung devices, try Volume Up, Center Home or Bixby, and Power buttons to boot into TWRP.

Once in TWRP, you can make a backup of your current stock firmware or custom ROM just in case you want to restore back to your current OS.  (See How to Backup/Restore ROM using TWRP!)

Step 3. Next, go to Wipe->Advanced Wipe, then select “Dalvik/ART Cache”, “System”, “Data”, and “cache”.  This will give you a clean wipe so you can install the GSI ROM on the first try.

Step 4. Next choose the Install Menu from the Home screen, then choose, “Install image”.  This will allow you to install image files using TWRP recovery, this way you won’t need a computer connected to your Android device which is required for the other fastboot method.

Find the GSI ROM image file you downloaded earlier ande extracted.

Choose “System image” and this will flash the GSI ROM in the system partition.  Now, since you are only flashing system image, your Android device will not be able to boot right away, it will auto-create boot image upon reboot.  Don’t worry if you get No OS message in TWRP as once you reboot once, you will have boot image.

Step 5. If you need to install Gapps(in most cases) and also root using Magisk, use the Reboot Menu to reboot back into TWRP recovery.  You MUST reboot once FIRST, so make sure you do this step.  If you do not need to flash Gapps or Magisk at this point, you can simply reboot system also.

Step 6. Once rebooted into TWRP recovery, flash your Gapps and/or Magisk.  Then reboot system.  You are done!

Once rebooted, you should see a nice Pixel boot animation like below if you installed the Pixel Experience GSI.

And finally you should see the Google welcome screen.  If you got this far, CONGRATS!  You have learned how to flash GSI(Generic System Image) on ANY Android device that is Project Treble compatible and has unlocked bootloader!  Pat yourself on the back and have a nice lemonade to satisfy your thirst.

 

FAQ

Q: Upon installing and rebooting to TWRP, TWRP gives me “Read Only Option” and I cannot access any files.
A: This means the GSI ROM you installed has encryption.  On Pixel or OnePlus phones and some you will be able to decrypt just using your pattern or code.   Try turning off your security such as fingerprint and reboot into TWRP first.  If TWRP still does not give you this option, you can flash No Verity Opt Encrypt ZIP file, flash in TWRP and reboot and encryption will be disabled.

Q: My GSI ROM is NOT BOOTING!
A: On phones like OnePlus 6, you may have to disable encryption completely to make it boot due to system-compatibility issues, reboot to TWRP, try flashing No Verify Opt Encrypt ZIP file in TWRP, then reboot.  It should then boot.

Q: Will this work on any of the older Android devices?
A: Most likely not but all Google Pixel devices are supported.

Q: Do I need root to do this?
A: No, you just need to unlock the bootloader on your Android device.

Q: I really enjoyed the tutorial, how do I thank you?
A: If you enjoyed this tutorial, you can donate to zedomax@gmail.com via Paypal, it would help me make more cool Android tutorials for the future.

Have a question?

Please post all your questions at the new Android Rehab Center at HighOnAndroid Forum, thank you for understanding!

Join the HighOnAndroid VIP Fans List for free help from Max and discounts on Android accessories.

Max Lee

Max Lee is the founder of HighOnAndroid.com. Max makes Android tutorials and review videos for people who want to get high on Android over at his YouTube channel and Korean YouTube channel.