# WebRTC Leak Test With a Proxy, and the Fix

> A WebRTC leak test with a proxy, run for real: Chromium showed the proxy IP to the page and the real IP to WebRTC. One setting closed it. Code and results.

[Home](https://quanticdata.io/) / [Blog](https://quanticdata.io/blog/) / WebRTC Leak Test With a Proxy, and the Fix

# WebRTC leak test: does your proxy hide your IP in the browser?

Proxies · Nov 20, 2026 · 5 min read · By [Aldo Morese](https://quanticdata.io/about/), founder of QuanticData

![A WebRTC leak test through a proxy in Chromium 149: the page sees the proxy exit, a T-Mobile IP in the US, while a STUN request outside the proxy returns the real line in Italy; with the WebRTC policy disable_non_proxied_udp the same test returns no candidate, and the card shows before and after.](https://quanticdata.io/blog/webrtc-leak-test-proxy/hero.webp?v=20261120h)

On this page

- [Why WebRTC can go around a proxy](https://quanticdata.io/blog/webrtc-leak-test-proxy/#why-webrtc-can-go-around-a-proxy)
- [Run the WebRTC leak test yourself](https://quanticdata.io/blog/webrtc-leak-test-proxy/#run-the-webrtc-leak-test-yourself)
- [What our leak test returned](https://quanticdata.io/blog/webrtc-leak-test-proxy/#what-our-leak-test-returned)
- [How to read a WebRTC candidate line](https://quanticdata.io/blog/webrtc-leak-test-proxy/#how-to-read-a-webrtc-candidate-line)
- [How to disable the WebRTC leak](https://quanticdata.io/blog/webrtc-leak-test-proxy/#how-to-disable-the-webrtc-leak)
- [A five-step leak check for any setup](https://quanticdata.io/blog/webrtc-leak-test-proxy/#a-five-step-leak-check-for-any-setup)
- [Residential or mobile behind a leak-free browser](https://quanticdata.io/blog/webrtc-leak-test-proxy/#residential-or-mobile-behind-a-leak-free-browser)

A WebRTC leak test checks whether your browser reveals your real IP through WebRTC while a proxy or VPN is on. In our test through a proxy, Chromium showed the proxy IP to the page but reported our real IP to WebRTC. Setting the WebRTC policy to "disable non-proxied UDP" closed the leak.

**Run it on the free credit.** Every QuanticData account gets $2 of free API usage per month.

[Start free — $2/month included](https://quanticdata.io/signup/?utm_source=blog&utm_medium=website&utm_campaign=blog-lead&utm_content=webrtc-leak-test-proxy) · [Explore Residential Proxies from $0.80/GB](https://quanticdata.io/residential-proxies/)

Everything below was run on 20 November 2026 with Chromium 149 driven by Playwright, through QuanticData Residential Basic and Mobile proxies, from an Italian broadband line. IPs are masked.

## Why WebRTC can go around a proxy

WebRTC is the browser feature behind video calls and peer-to-peer transfers. To connect two browsers, it asks a STUN server "what is my public address?" over UDP. An HTTP proxy, or a SOCKS5 proxy set in the browser, carries the page's requests; that UDP request goes out on your own connection and comes back with your own address. Any page can start this with a few lines of JavaScript and read the answer, so it can compare the IP that loaded the page with the IP that WebRTC found.

## Run the WebRTC leak test yourself

This is the test we ran. It opens a page through the proxy, asks a public STUN server for candidates, and prints what WebRTC found:

```javascript
import { chromium } from 'playwright';

const browser = await chromium.launch({
  proxy: { server: 'http://mobile.quanticdata.io:8080',
           username: 'USER-country-us-type-mobile-sid-wr01-ttl-30m', password: 'PASS' },
  // args: ['--force-webrtc-ip-handling-policy=disable_non_proxied_udp'],
});
const page = await browser.newPage();
await page.goto('https://ipinfo.io/json');            // the IP the page sees
const candidates = await page.evaluate(async () => {
  const out = [];
  const pc = new RTCPeerConnection({ iceServers: [{ urls: 'stun:stun.l.google.com:19302' }] });
  pc.createDataChannel('probe');
  pc.onicecandidate = (e) => e.candidate && out.push(e.candidate.candidate);
  await pc.setLocalDescription(await pc.createOffer());
  await new Promise((r) => setTimeout(r, 6000));
  return out;                                          // what WebRTC found
});
```

A candidate of type `srflx` ("server reflexive") carries the public IP the STUN server saw. If that IP is not the proxy's, the browser leaks.

## What our leak test returned

| Run | IP the page saw | WebRTC candidates | Leak |
| --- | --- | --- | --- |
| No proxy | Our line, Italy | mDNS host (.local), srflx with our Italian IP | none to hide |
| Residential Basic, default | A US home IP | mDNS host, srflx with our Italian IP | yes |
| Mobile, default | T-Mobile USA | mDNS host, srflx with our Italian IP | yes |
| Residential Basic, policy set | A US home IP | none | no |
| Mobile, policy set | T-Mobile USA | none | no |

Two things stand out. The local address was already hidden: Chromium replaces it with a random `.local` name (mDNS), so no 192.168 address appeared. The public address was not: by default, every proxied run still handed the page our Italian IP through the srflx candidate. With the policy set, WebRTC produced no candidate at all, so there was nothing to read.

We repeated it on browserleaks.com/webrtc, a public leak test page, through the mobile line. By default it reported "No Local IP Leak" and "WebRTC IP doesn't match your Remote IP", with our Italian address as the public WebRTC IP. With the policy set, it reported "No Leak" and a dash for both local and public IP.

**Try it on your own targets.** Every QuanticData account gets $2 of free API usage per month.

[Start free — $2/month included](https://quanticdata.io/signup/?utm_source=blog&utm_medium=website&utm_campaign=blog-inline&utm_content=webrtc-leak-test-proxy) · [Explore Residential Proxies from $0.80/GB](https://quanticdata.io/residential-proxies/)

## How to read a WebRTC candidate line

These are the two lines Chromium produced in the default run through the mobile proxy, with our own address masked:

```
candidate:1921712961 1 udp 2113937151 4410eefb-....local 57548 typ host generation 0 ...
candidate:3454085914 1 udp 1677729535 [our IP, masked] 57548 typ srflx raddr 0.0.0.0 rport 0 generation 0 ...
```

| Field | In our line | Meaning |
| --- | --- | --- |
| Protocol | `udp` | WebRTC gathers over UDP, which an HTTP proxy does not carry |
| Priority | `2113937151`, `1677729535` | Host candidates rank above server reflexive ones |
| Address | a `.local` name, then our IP | The local address is hidden behind mDNS; the public one is plain |
| Port | `57548` | The UDP port the browser opened |
| Type | `host`, `srflx` | host = this device, srflx = the address the STUN server saw. A third type, `relay`, comes from a TURN server. |

A leak test page only has to read the address in the `srflx` line and compare it with the IP of the HTTP request. In our default runs they differed: the page came from the proxy, the srflx address from Italy.

## How to disable the WebRTC leak

| Where | Setting | Tested here |
| --- | --- | --- |
| Chromium or Chrome started by a script (Playwright, Puppeteer, Selenium) | Launch argument `--force-webrtc-ip-handling-policy=disable_non_proxied_udp` | Yes, Chromium 149: no candidate left |
| Chrome and Brave with the QuanticData extension | WebRTC leak protection while a session is live | Covered in our [Chrome proxy setup](https://quanticdata.io/blog/chrome-proxy-setup/) and [Brave proxy setup](https://quanticdata.io/blog/brave-proxy-setup/) guides |

"Disable non-proxied UDP" lets WebRTC use only paths that go through the proxy, so the STUN request that found our real address is never sent. The [QuanticData Chrome extension](https://quanticdata.io/chrome-extension/) offers WebRTC leak protection while a session is live. For browser automation, add the launch argument next to the proxy settings in your script; the rest of the proxy options are in our [Playwright proxy guide](https://quanticdata.io/blog/playwright-proxy/).

## A five-step leak check for any setup

1. Note your real IP with the proxy off.
2. Turn the proxy on and load a page that shows your IP: it should be the proxy's.
3. Run a WebRTC leak test (the script above, or a public test page).
4. Look at the public IP WebRTC reports. If it is the address from step 1, you leak.
5. Set the policy, restart the browser, and run step 3 again until no real IP appears.

Check DNS while you are at it: our [DNS leak test through a proxy](https://quanticdata.io/blog/dns-leak-test-proxy/) shows the same before-and-after for name lookups.

## Residential or mobile behind a leak-free browser

Once WebRTC is closed, the page sees one consistent address: the proxy's. Residential Basic and Premium give home IPs in the country you pick, Mobile gives carrier IPs such as the T-Mobile exits in our runs. The plans are on our pages for [residential proxies](https://quanticdata.io/residential-proxies/) and [mobile proxies](https://quanticdata.io/mobile-proxies/), with a [Residential Basic free trial](https://quanticdata.io/residential-proxy-free-trial/) to start.

WebRTC is one leak; the browser's time zone, language and fingerprint are others, covered in [browser fingerprinting](https://quanticdata.io/blog/how-to-browser-fingerprint/). For the wider picture of what a site can still learn, see [how to hide your IP address](https://quanticdata.io/blog/how-to-hide-ip-address/).

### Sources & further reading

- [RFC 8828: WebRTC IP Address Handling Requirements](https://www.rfc-editor.org/rfc/rfc8828)
- [RFC 8489: Session Traversal Utilities for NAT (STUN)](https://www.rfc-editor.org/rfc/rfc8489)
- [MDN: RTCIceCandidate](https://developer.mozilla.org/en-US/docs/Web/API/RTCIceCandidate)
- [Playwright: BrowserType.launch proxy option](https://playwright.dev/docs/api/class-browsertype#browser-type-launch)

## FAQ

Quick answers on webrtc leak test.

[Something else? Ask us](mailto:hello@quanticdata.io)

### What is a WebRTC leak?

WebRTC asks a STUN server for your public address over UDP, outside the proxy, and a page can read the answer. In our test through a proxy, Chromium gave the page the proxy IP but reported our real Italian IP through WebRTC.

### How do I test for a WebRTC leak?

With the proxy on, open a WebRTC leak test page or run an RTCPeerConnection with a STUN server and look at the srflx candidate. If its IP is your real one, you leak.

### Does WebRTC go through the proxy?

Not unless the policy is set: WebRTC is a browser feature, and in our test Chromium sent the STUN request outside the proxy by default, through both a residential and a mobile proxy. The WebRTC policy "disable non-proxied UDP" stopped it: no candidate at all.

### How do I disable WebRTC leaks in Chrome?

For Chrome started by a script, add `--force-webrtc-ip-handling-policy=disable_non_proxied_udp` to the launch arguments. In everyday Chrome or Brave, the QuanticData extension offers WebRTC leak protection while a session is live.

### Does WebRTC leak my local IP address?

Not in Chromium 149 in our test: the local address appeared only as a random .local name (mDNS). The public IP was the one that leaked.

## Proxies for a browser that does not leak

Residential and mobile proxies, and a Chrome extension that switches on WebRTC leak protection while it is connected.

[Start free — $2/month included](https://quanticdata.io/signup/?utm_source=blog&utm_medium=website&utm_campaign=blog-end&utm_content=webrtc-leak-test-proxy) · [Explore Residential Proxies from $0.80/GB](https://quanticdata.io/residential-proxies/)

## Related reading

- [HTTP vs HTTPS: What a Proxy Sees in Each](https://quanticdata.io/blog/http-vs-https-proxy/): Proxies · HTTP sends requests as plain text; HTTPS wraps the same requests in TLS. We put a logging relay in front of a residential proxy line on 20 November 2026 and captured both: 340 readable bytes for http://, and for https:// one CONNECT line followed by 803 encrypted bytes.
- [Change Proxy IP by Link: Rotation Links](https://quanticdata.io/blog/change-proxy-ip-by-link/): Proxies · A rotation link is a URL that restarts one sticky session: open it and the session starts again; in our test of 20 November 2026 each of three calls was followed by a new exit IP. Below: the API call that creates the link, what it answered, the 10-second pause between rotations, and what to do on Mobile and Residential Premium.
- [ISP Proxy API: Stock, Quote and Buy by Code](https://quanticdata.io/blog/isp-proxy-api/): Proxies · The Premium ISP endpoints let a script do what the configurator does: read the catalog with live stock, pick a pool or a city and carrier, get a server-side quote and buy from the balance. Below: each call with the answer we got on 20 November 2026, what "currently unavailable" means, and how to write a buyer that never pays twice.

---

Source: https://quanticdata.io/blog/webrtc-leak-test-proxy/ · Site index for AI: https://quanticdata.io/llms.txt
