How to Profile HWUI Rendering in Android Developer Options to Diagnose UI Jutter and Frame Drops

Delivering smooth user experiences on Android requires maintaining consistent display frame rates. On standard 60Hz displays, each visual frame must be fully rendered within 16.6 milliseconds; on modern 120Hz high-refresh-rate displays, the render budget drops to just 8.3 milliseconds. When an application misses this deadline due to complex view hierarchies, heavy main-thread layout calculations, or unoptimised bitmap decoding, Android drops frames, creating visible stutter known as “jank”.

To pinpoint the exact phase of the rendering pipeline causing frame drops without attaching a USB cable or running desktop profiling tools, Android provides a built-in diagnostic overlay: Profile HWUI rendering (formerly known as Profile GPU rendering).

What is HWUI Rendering?

HWUI is Android’s hardware-accelerated 2D rendering pipeline that translates Android UI View hierarchies into OpenGL ES or Vulkan GPU drawing commands. When you activate Profile HWUI rendering, the operating system renders a dynamic, colour-coded bar graph across the bottom of the screen. Each vertical bar represents a single rendered frame, with individual coloured segments detailing how much time was spent on specific pipeline stages.

Understanding the Render Time Thresholds

The on-screen graph displays a horizontal green line representing the target frame deadline:

  • Below the Green Line: The frame rendered within budget (under 16.6 ms on 60Hz or under 8.3 ms on 120Hz). The animation remains buttery smooth.
  • Above the Green Line: The frame exceeded its processing budget, resulting in a dropped frame and visible scrolling stutter.

Colour-Coded Bar Segment Breakdown

Each vertical frame bar is divided into coloured bands representing distinct rendering phases:

Bar Segment Colour Pipeline Phase Troubleshooting Diagnosis
Orange Swap Buffers / CPU wait CPU is waiting for the GPU to finish rendering previous commands; indicates GPU bottlenecks.
Red Command Issue Time spent by Android converting drawing operations into GPU commands; indicates complex custom views.
Blue Draw Phase Time spent creating display lists; caused by expensive onDraw() logic or heavy bitmap allocations.
Light Blue Sync & Upload Time transferring bitmaps and textures from CPU memory to GPU VRAM; indicates unscaled images.
Green Measure / Layout Time spent executing onMeasure() and onLayout() on views; indicates deep layout nesting.
Dark Green Input Handling Time spent processing touch events; indicates main-thread work triggered inside click listeners.

Step-by-Step: Enabling Profile HWUI Rendering

  1. Open the Settings app on your Android device.
  2. Navigate to System > Developer options (on Samsung Galaxy devices running One UI, select Developer options at the bottom of the main Settings list).
  3. Scroll down to the Monitoring section.
  4. Tap Profile HWUI rendering (or Profile GPU rendering).
  5. In the popup modal, select On screen as bars.
  6. A real-time bar graph will immediately appear anchored along the bottom edge of your screen.

Testing and Diagnosing App Performance

With the overlay active, open the application you wish to evaluate and perform standard gestures:

  1. Scroll Through Lists: Rapidly scroll through a RecyclerView or feed. If tall bars shoot past the green line, observe which colour segment dominates the spike.
  2. Analyse Large Blue/Light Blue Spikes: If blue or light blue spikes occur as new items scroll into view, the app is decoding unoptimised images on the UI thread or invalidating whole layouts unnecessarily.
  3. Analyse Green Spikes: Prominent green bars indicate that scrolling triggers expensive recursive layout passes across deeply nested view hierarchies.

Disabling the Overlay

Once diagnostics are concluded, return to Settings > System > Developer options > Profile HWUI rendering and select Off to restore your standard display interface.

Frequently Asked Questions

Can I export HWUI rendering logs to my computer for quantitative analysis?

Yes. In the Profile HWUI rendering dialogue, select In adb shell dumpsys gfxinfo. Then connect your device to your computer and run adb shell dumpsys gfxinfo <package_name> to export detailed CSV frame statistics.

Does Profile HWUI rendering profile Flutter or Unity apps?

The HWUI profiler measures native Android View frameworks. While it displays total frame render times for Flutter and game engines, the individual coloured sub-segments apply strictly to native Android UI components.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.