Debug Android Emulators

To allow the HTTP Debugger to decrypt the SSL traffic from Android Emulators (Android Virtual Devices), you need to install our trusted CA Certificate on your Android Emulator, or ignore the SSL errors in your application.

Method 1: Install the trusted CA Certificate on your Android Emulator

Get the HTTP Debugger Pro CA Certificate from:


Install it on your device as described in the following article at Stackoverflow.

Method 2: Ignore SSL errors in your application

IMPORTANT: Ensure that you are doing this only in the Debug mode!

Define a helper function to disable certificate errors:

    private static void disableSSLCertificateErrors() {
        TrustManager[] trustAllCerts = new TrustManager[] { new X509TrustManager() {
            public X509Certificate[] getAcceptedIssuers() {
                return null;

            public void checkClientTrusted(X509Certificate[] arg0, String arg1) throws CertificateException {
                // Not implemented

            public void checkServerTrusted(X509Certificate[] arg0, String arg1) throws CertificateException {
                // Not implemented
        } };

        try {
            SSLContext sc = SSLContext.getInstance("TLS");

            sc.init(null, trustAllCerts, new;

        } catch (KeyManagementException e) {
        } catch (NoSuchAlgorithmException e) {

Call helper function before establishing a connection to the server:

    public static void getHTML() throws Exception {

        StringBuilder result = new StringBuilder();
        URL url = new URL("");
        HttpURLConnection conn = (HttpURLConnection) url.openConnection();
        InputStream stream = conn.getInputStream();
        BufferedReader rd = new BufferedReader(new InputStreamReader(stream));
        String line;
        while ((line = rd.readLine()) != null) {


HTTP Debugger screenshot from Android Studio