In this guide, we will tell you how you can easily extract payload.bin (Android) file which is found in Android Stock Firmware/OTA Zip files. With this guide, you can extract payload.bin in a matter of a few minutes.
Android has come a long way in terms of hardware and software. Especially in software, the difference between the one we had a couple of years ago and what we have no is day and night. One of the beauties of Android is being open source. And we love to tinker around Android so much so that there are times when some people would run a different ROM every single day.
Custom ROMs are built by modding the stock ROMs. To modify the stock ROMs, we would need to extract the stock ROM Firmware file and then modify the stuff we need. We even wrote a tutorial on how to extract system.img and system.new.dat files on Windows. Turns out, manufacturers are using a different method to deliver the updates to their phones. Read ahead to know more and learn how to extract payload.bin Android Update file.
Table of Contents
What is payload.bin file?
Yesterday, I decided to mess around with OnePlus 6T firmware update package. I usually extract stock firmware packages to look for new wallpapers and ringtones. So, when I extracted the firmware zip file, there was a new type of file called payload.bin. Take a look below:
Usually, when I extract the OnePlus stock firmware zip file, there would be multiple “.img” file such as system.img, boot.img etc. But it was different this time. Seems like OnePlus has decided to take a new route to deliver the OTA Firmware updates to its devices. Turns out the change is due to the introduction of the A/B system update.
How To Extract payload.bin Android File?
- Make sure you have the latest version of Python installed on your PC. This tutorial NEEDS python to be installed on your PC.
- Download and extract the payload_dumper.zip python script. You will get a folder named ‘payload_dumper’.
- Copy the ‘payload.bin’ file which you want to extract into the ‘payload_dumper’ folder where scripts like ‘payload_dumper.py’ are also present.
- Hold down ‘Shift Key’ and right-click anywhere inside the folder and select ‘Open PowerShell window here’ or ‘Open Command window here’ (either is fine).
- Once the PowerShell window/command window opens, run the below command:
python -m pip install protobuf
- Wait for the process to complete. It would only take a couple of seconds.
- After making sure that the payload.bin file is available in the same folder, execute the below command:
python payload_dumper.py payload.bin
- This will start to extract the images within the payload.bin file to the current folder you are in. Wait for the process to complete.
All the contents of the payload.bin file will be extracted in the same folder as you are currently in. If not look for a folder named ‘output’. The contents would be present there. This is the easiest way to extract payload.bin Android file on Windows.
Need help? Drop a comment below!