How to Use Logcat on BlueStacks 5 Using HD-Adb.exe Print

  • 1

BlueStacks 5 no longer supports external ADB connections in the same way as BlueStacks Tweaker. Instead, you can directly access ADB from the built-in tools provided with BlueStacks itself. This guide shows you how to launch a shell and capture logs using HD-Adb.exe in the Bluestacks_ext directory.

Prerequisites

  • BlueStacks 5 installed and running
  • Your APK installed and run at least once inside BlueStacks
  • Basic knowledge of using Windows Command Prompt or Terminal

Step-by-Step Guide

1. Locate HD-Adb.exe

  1. Open File Explorer
  2. Navigate to the following folder:
    C:\Program Files\BlueStacks_nxt\Bluestacks_ext
  3. Ensure the file HD-Adb.exe is present in this folder

2. Open Terminal in Bluestacks_ext

  1. Hold Shift and right-click inside the Bluestacks_ext folder
  2. Select “Open PowerShell window here” or “Open in Terminal”
  3. This ensures that commands are run in the correct context

3. Open a Shell into BlueStacks

Run the following command to enter the Android shell:

.\HD-Adb.exe shell

You are now inside the Android shell environment within BlueStacks 5.

4. Start Logcat

Once inside the shell, run:

logcat

This will display live log output from the emulator. You can observe errors, crashes, and debug information from your APK.

Filtering and Saving Logs

View Only Errors

logcat *:E

Search for a Specific Tag or App

logcat | grep com.yourapp.package

Clear Logs Before Testing

logcat -c

Save Logs to a File

From outside the shell (directly in terminal), you can run:

.\HD-Adb.exe logcat > log.txt

This will save the output to a file named log.txt in the current folder.

Common Issues

  • No logs showing? Make sure your app is running and generating output
  • Command not recognized? Make sure you’re inside the Bluestacks_ext directory and using .\HD-Adb.exe
  • Not entering the shell? If the shell closes instantly, try launching BlueStacks first, then re-running the command

Example: Debugging a Crash

  1. Install and run your APK in BlueStacks 5
  2. Open the terminal in Bluestacks_ext and enter .\HD-Adb.exe shell
  3. Run logcat to monitor output
  4. Watch for errors such as:
    FATAL EXCEPTION: main java.lang.NullPointerException: Attempt to invoke...
  5. Use MT Manager to inspect and fix the referenced class or method

Summary

  • BlueStacks 5 includes a built-in ADB tool called HD-Adb.exe
  • You can use this to run logcat and monitor your app’s behavior in real time
  • Logs can be filtered, cleared, or saved for debugging

If you’re not sure how to interpret your logcat output, feel free to submit a support ticket and we’ll help you analyse it.


Was this answer helpful?

« Back