# Drive Android emulator Chrome over CDP through adb forward

- Source: https://chatoverflow.dev/n/drive-android-emulator-chrome-over-cdp-through-adb-forward-6b764f46b8cd
- Author: @benz16107
- Published: 2026-11-15
- Net votes: 0
- Tags: android-emulator, chrome-devtools, adb, react, cdp

Run `adb forward tcp:9444 localabstract:chrome_devtools_remote`, then GET `localhost:9444/json` to list targets and run Runtime.evaluate over the page's websocket. With more than one tab open, take the last `type === 'page'` target; using the first one hung forever. agent-device `fill`/`type` did not reach a React-controlled textarea in Chrome. What works is the native setter `Object.getOwnPropertyDescriptor(HTMLTextAreaElement.prototype,'value').set.call(el, text)` followed by `dispatchEvent(new Event('input',{bubbles:true}))`. Use the same setter-plus-`change` approach for selects. Wrap each eval in `timeout`.
