This guide shows how to install the Android Debug Bridge (ADB) using Android Studio and then use it to manually flash an official OTA update from Google on a Pixel or Nexus device. This is useful if you want to install an update before it rolls out to your device, or if an OTA failed and you need to re-apply it.
⚠️ Important notes before you begin:
- Make sure your device is charged to at least 50% before starting.
- Back up important data (photos, messages, etc.) before flashing an OTA.
- This process uses official Google OTA files; it does not require unlocking the bootloader or wiping data.
- Only use OTA files that match your exact device model and carrier (if applicable).
1. Install Android Studio and ADB
ADB is included in the Android SDK Platform Tools, which come with Android Studio. Follow these steps to install it:
- Download and install Android Studio from the official site:
https://developer.android.com/studio - Launch Android Studio and go through the setup wizard (you can accept the default settings).
- Once Android Studio is installed, open it and go to Tools → SDK Manager.
- In the SDK Manager, go to the SDK Tools tab and make sure Android SDK Platform-Tools is checked.
- Click Apply and then OK to install the Platform Tools.
- After installation, the ADB tools will be located in a folder like:
Windows: C:UsersYourNameAppDataLocalAndroidSdkplatform-tools\
macOS: /Users/YourName/Library/Android/sdk/platform-tools/
Linux: /home/YourName/Android/Sdk/platform-tools/
Remember this path; you’ll need it to run ADB commands.
2. Enable Developer Options and USB Debugging
On your Android device, you need to enable Developer Options and USB Debugging:
- Open Settings on your phone.
- Go to About phone (or About tablet).
- Tap Build number 7 times until you see a message like “You are now a developer!”
- Go back to the main Settings screen and open Developer options.
- Enable USB debugging.
- When prompted, allow USB debugging for your computer by tapping Allow on the device.
3. Download the Correct OTA File from Google
Google provides full OTA images for Nexus and Pixel devices. To download the right file:
- Visit the official OTA page:
https://developers.google.com/android/ota - Find your device model (e.g., Pixel 6, Pixel 7 Pro, etc.) and the correct build (e.g., TQ3A.230901.001).
- Download the OTA zip file for your device and save it to your computer.
- Move the OTA zip file into the
platform-toolsfolder where ADB is installed (from step 1).
4. Connect Your Device and Test ADB
Now connect your device to your computer and verify that ADB can see it:
- Connect your phone to your computer using a USB cable.
- On Windows, open Command Prompt or PowerShell. On macOS or Linux, open Terminal.
- Navigate to the
platform-toolsdirectory. For example, on Windows:
cd C:UsersYourNameAppDataLocalAndroidSdkplatform-tools
- Run this command to list connected devices:
adb devices
You should see your device’s serial number listed with the word “device” next to it. If you see “unauthorized”, unlock your phone and tap “Allow” on the USB debugging prompt.
5. Reboot into Recovery and Sideload the OTA
Now you can flash the OTA update using ADB sideload:
- Make sure the OTA zip file is in the same
platform-toolsfolder as ADB. - In the terminal/command prompt, run this command to reboot your device into recovery:
adb reboot recovery
- When the device reboots, you’ll see the Android recovery menu (a robot with an exclamation mark).
- Press and hold the Power button, then press the Volume Up button once to enter the recovery menu.
- Use the Volume buttons to highlight Apply update from ADB and press the Power button to select it.
- Back on your computer, run this command (replace
ota_file.zipwith the actual filename):
adb sideload ota_file.zip
ADB will now transfer and apply the OTA update. This can take several minutes; do not disconnect the cable or turn off the device.
6. Reboot and Verify the Update
Once the sideload is complete:
- On the device, use the Volume buttons to highlight Reboot system now and press the Power button.
- Wait for the device to boot normally.
- Go to Settings → About phone and check that the Android version and build number match the OTA you just installed.
Troubleshooting Tips
- “adb: command not found” – Make sure you are in the
platform-toolsdirectory, or add that folder to your system PATH. - Device not listed in
adb devices– Check USB debugging is enabled, try a different USB cable/port, and ensure the device is unlocked when prompted. - Sideload fails with an error – Double-check that you downloaded the correct OTA file for your exact device model and that the file is not corrupted (verify the SHA-256 checksum if provided).
- Recovery menu does not appear – Ensure the device is fully powered on before running
adb reboot recovery.
By following these steps, you can install ADB through Android Studio and safely flash an official Google OTA update without losing your data.