How To Install Android 7.1 AOSP Nougat Custom ROM on Xperia Z2

AOSP brings latest custom firmware based on Android 7.1 Nougat for Sony Xperia Z2. Now Xperia Z2 users can enjoy the latest Android OS version. Xperia Z2 or Z3 will not be updating to the latest Android OS mentioned by Sony earlier, but the developers build this amazing Custom ROM for Xperia Z2. Android 7.1 Nougat AOSP custom ROM is a very stable and fully stock Android based so don’t expect anything fancy here. This is not an official ROM released by Sony, but it is a custom ROM which is developed by the third-party developers.

In this guide; we will tell you that how to install Android 7.1 Nougat AOSP Custom ROM on your Xperia Z2 using CWM recovery. All you need to have the latest version of a custom recovery like CWM or TWRP on your phone pre-installed, to flash the ROM .zip file. Before proceeding to the installation guide, don’t forget to take a full backup of all your important data because while installing this Android 7.1 Nougat based custom firmware, your entire data will be wiped clean like a brand new phone. If you are interested, then go ahead and follow the given steps.



This given guide containing the AOSP Android 7.1 Nougat ROM is only working with Sony Xperia Z2. Do not apply this guide on any other or incorrect variant, as a result, the device might get bricked. You can verify the model number of your device by going to Settings > About Phone.

Warning: will not be responsible for any damage occurred to the device during or after the installation of this AOSP Android 7.1 Nougat ROM on your Xperia Z2. Proceed at your risk.


  • Take a proper backup of all your important data like your SMS, MMS, APN Settings, Call Logs, Contacts and media files, etc. with a recommended custom recovery such as TWRP recovery. In case anything goes wrong then you’ll be able to restore your data.
  • Download and configure ADB and Fastboot on your PC. Get the full Android SDK from here.
  • Download and install Sony Xperia Z2 (Sirius) USB Drivers on your PC.
  • Enable USB debugging on your Xperia Z2 by going to Settings > Developer Options.
  • Make sure that you have at least 80% of battery charge on your device before proceeding to the installation guide.

Required Files:

Steps to Update Sony Xperia Z2 to Android 7.1 AOSP Nougat Custom ROM:

Step No 1: – First, download AOSP Android 7.1 ROM on the desktop of your PC for Sony Xperia Z2.

Step No 2: – Extract boot.img from the zip file separately.

Step No 3: – Now, plug your phone with PC using its USB data cable and mount its mass memory.

Step No 4: – Transfer the downloaded Android 7.1 ROM zip and Google Apps package .zip files to the root folder of your SD card on the phone.

Step No 5: – Also, copy/paste the boot.img file to android-sdk-windows\platform-toolsdirectory on your PC.

Step No 6: – Power OFF the device to boot into Bootloader Mode.

Step No 7: – Power ON the Z2 by pressing and holding Volume Up button while connecting it again with the USB cable. The phone LED will turn blue, and it will get into the Bootloader Mode.

Step No 8: – While the phone is in Fastboot Mode, go to android-sdk-windows\platform-tools directory on the PC and within the folder, open Command Prompt.

9: – Type the following command and press Enter.


Step No 10: – Next, type this command and hit Enter.


Step No 11: – Once in the Recovery Mode. Turn ON the Xperia Z2 while pressing the Volume Up or Volume Down buttons a few times till the LED light turn pink or any other colour.

Step No 12: – Once you are in ClockworkMod Recovery, select perform a full data wipe by selecting “wipe data/factory reset” as shown below. Use the Power button to select everything while in the Recovery Mode.

Step No 13: – Perform a cache wipe by navigating to “wipe cache partition”.

Step No 14: – Its recommended to perform a wipe of your Dalvik cache. Wipe Dalvik cache will help to prevent facing boot loops or any other errors.

CWM Recovery -> Advanced -> wipe dalvik cache.

Step No 15: – Go back to the main menu of Recovery,  select “install zip from SD card”. Now select “choose zip from sd card”. You can use volume keys to navigate to the Android 7.1 ROM zip file that you have already transferred to the root folder of your SD card. Select it using the Power button and confirm the installation to begin.

Step No 16: – Repeat the above-given process to install Google Apps package on your Z2.

Step No 17: – Once the installation is completed, navigate to “+++++Go Back+++++” and reboot the phone by selecting “reboot system now” from the recovery menu.

You might also like
1 Comment
  1. Kshitij Joshi says

    Does this work with the D6502 model?

Leave a Reply

android 1, android, android studio, android device manager, android pie, android games, android one, android emulator, android versions, android emulator for pc, android apps, android app development, android authority, android apk, android arsenal, android apps on pc, android auto, android activity lifecycle, android app download, android architecture, android codes, android color codes, android central, android cdc driver, android car stereo, android course, android camera, android omponents, android box, android beta, android best games, android beam, android backup, android backup to pc, android basics, android games, android games apk, android games free download, android go, android gamer, android games 2018, android games on pc, android glide, android game development, android emulator online, android emulator download, android emulator for mac, android emulator for windows 10, android file transfer, android file host, android framework, android flash tool, android firmware, android hacking tools, android hd wallpapers, android hard reset, android heavy games, android data recovery, android keyboard, android kitkat, android keyboard apk, android keylogger, android imei check, android multi tools, android manager, android material design, android mobile games, android modded games, android latest version, android lollipop, android nougat, android oreo, android pie, android play store, android pc suite, android pie update, android police, android programming, android questions, android ringtones, android root, android root apk, android root apps, android tv box, android themes, android tools, android wallpapers, android wallpapers hd, android usb driver, android ui design, android update 8.0, android update 9.0, android studio, android sdk manager, android secret codes, android vidmate, android youtube downloader, android youtube downloader apk, android youtube background play, android zapya