---
title: Inspecting elements in Android Webview
url: https://calvin.my/posts/inspecting-elements-in-android-webview
published: 2025-04-14
updated: 2026-09-17
category: Development
tags:
- Android
- webview
- debug
- Kotlin
summary: The post explains how to inspect web content displayed in an Android WebView using Chrome’s remote debugging tools. It outlines enabling Developer Mode and USB debugging on an Android device, connecting it to a computer, configuring the app to allow WebView debugging, launching a debug build, and opening the WebView. Chrome then detects the connected device and provides access to element inspection.
---

# Inspecting elements in Android Webview

This article shows how to inspect web page elements within an Android Webview.

* * *

## Preparation

1. Enable "Developer Mode" -\> "USB debugging" in your phone.

   ![](https://camy-pub.s3.ap-southeast-1.amazonaws.com/9ef14712-146b-4cae-b1fe-a8357aaed498.png)

2. Connect your phone to your laptop with a USB cable. When the permission prompts on your phone, click "Allow."

## Steps to enable

1. Open a Google Chrome browser and go to [chrome://inspect/](chrome://inspect/)

2. You should see a remote device connected.

   ![](https://camy-pub.s3.ap-southeast-1.amazonaws.com/0aca7456-4720-4a40-863d-c8e446a93084.png)

3. In your Android Studio, place the code to enable Webview debugging.

   ```kotlin
   WebView.setWebContentsDebuggingEnabled(true)
   ```

4. Run debug deployment in your Android Studio and wait for the app to launch.

5. Open the Webview within your App.

6. Back to Chrome Browser, and you can perform inspect elements.
