Power Your Software Testing with AI Agents and Cloud
The Native AI-Agentic Cloud Platform to Supercharge Quality Engineering. Test Intelligently and Ship Faster.
- TestMu AI (Formerly LambdaTest)
- /
- Blog
- /
- Selenium 4 Is Now W3C Compliant: All You Need To Know
Selenium 4 Is Now W3C Compliant: All You Need To Know
Selenium 4 is now W3C compliant - read on to know more about Selenium 4 and its Support To W3C WebDriver Protocol. Also, find out how this impacts the Selenium community.
Last Updated on:
On This Page
- Introduction: WebDriver in Selenium 4
- Communication between the WebDriver and Browser
- The JSON Wire Protocol
- WebDriver W3C Protocol in Selenium 4
- Major Advantages of the WebDriver W3C Protocol
- JSON Wire Protocol vs. WebDriver W3C Protocol
- Impact of WebDriver W3C Protocol on an existing implementation
- Impact of WebDriver W3C Protocol on Automation Tests executed on TestMu AI
- AI Coding Agents and WebDriver
This article is a part of our Content Hub. For more in-depth resources, check out our content hub on Selenium 4.
Selenium 4 is the actively maintained, current major version of Selenium, and it has shipped as a stable release for years. It introduced salient properties like relative locators, improved Selenium IDE, and an improved Selenium Grid design that introduces a 'fully distributed mode' for automated Selenium testing. Apart from these visible changes, a major under-the-hood (or architectural) change is that WebDriver APIs in Selenium 4 follow the W3C (World Wide Web Consortium) in its implementation.

This Selenium 4 complete tutorial covers everything you need to know about Selenium 4.
Here are some questions that might come to your mind regarding Selenium WebDriver APIs becoming W3C standardized in Selenium 4:
- What are the key Selenium 4 features?
- How does Selenium 4 becoming a W3C standard impact the Selenium community?
- What would be the significant advantages of the W3C WebDriver Protocol?
- Will this change impact the test scenarios that were working seamlessly on Selenium 3?
- Do we need to change the implementation tested on Selenium 3 to accommodate W3C standardized Selenium WebDriver APIs in Selenium 4?
This article would help answer these lingering questions as we deep dive into what W3C compliance in Selenium 4 means for the Selenium framework users. You can read more about what Is Selenium? If you are preparing for an interview you can learn more through Selenium interview questions.
See How Selenium 4 Relative Locator Can Change The Way You Test?
Introduction: WebDriver in Selenium 4
As mentioned on the W3C website, WebDriver is a remote control interface that enables introspection and control of user agents. It provides a platform and language-neutral wire protocol so that our-of-process programs can remotely instruct web browsers’ behavior.
WebDriver provides a set of interfaces (or Selenium locators) that aid in controlling the behavior of a user agent and discovering & manipulating the DOM elements on web pages (or documents). Apart from Selenium, WebDriver APIs are used in other automation tools like Appium, used mainly for mobile applications’ web testing.
Stable support for the W3C protocol was added in Selenium v3.8 through Selenium v3.11, as seen from W3C related patches in that era's Selenium 3 releases. The Selenium project's plan to migrate fully to the W3C protocol is complete: Selenium 4 has shipped as the stable, actively maintained major version for years, with the WebDriver W3C protocol on by default.
All current browsers, including Chrome, Firefox, Safari, and Edge, are W3C compliant. Internet Explorer is retired and no longer under active development, so it is not part of that current set. With Selenium 4, you no longer need to add 'tweaks' in the test script to make it work across different browsers, as everything (i.e., browsers & WebDriver APIs) runs in the W3C standard protocol.
With WebDriver becoming completely W3C standardized, you can now use it across different frameworks without compatibility issues.
Communication Between The WebDriver and Browser
In Selenium, the WebDriver offers a set of APIs that lets you discover and perform relevant operations (i.e., click, sendKeys, etc.) on the web elements present in the document (or page). A secure connection with the web browser is established using the corresponding ‘browser drivers.’ The browser is the end-point of execution.
Check here to know more about What is Selenium?
As communication is happening between the web browser and Selenium WebDriver, both the parties should follow a set of rules (or protocol) that can be understood. With Selenium 4, the WebDriver and browser follow the same protocol (i.e., W3C), offering numerous advantages compared to the WebDriver used in versions before Selenium 4.
The JSON Wire Protocol
For Selenium versions earlier than Selenium 4, the JSON Wire Protocol was used for communicating with the web browser from the local end. As the Selenium Client libraries (i.e., Client) use the JSON protocol, and the web browser uses the W3C protocol, API encoding and decoding was involved in the entire process.

Starting with Selenium 4, the JSON Wire Protocol is no longer supported. For teams that still need to run test scenarios written against the old protocol, Selenium's Java bindings and Selenium Server keep backward compatibility, so tests that worked on Selenium 3 continue to run on Selenium 4.
Austin Siewert
Co-Founder, Steadfast Systems
Discovered @TestMu AI yesterday. Best browser testing tool I've found for my use case. Great pricing model for the limited testing I do 👏
3M+ Devs and QAs rely on TestMu AI
Deliver immersive digital experiences with Next-Generation Mobile Apps and Cross Browser Testing Cloud
This certification is ideal for testing professionals who want to acquire advanced, hands-on knowledge in Selenium automation testing.
Here’s a short glimpse of the Selenium Advanced certification from TestMu AI:
WebDriver W3C Protocol in Selenium 4
'WebDriver W3C' is the protocol Selenium 4 introduced in place of the older JSON Wire Protocol. It carries an endorsement from W3C (World Wide Web Consortium), the community that works on web standards development. W3C Working Draft and W3C Editor's Draft are excellent resources to keep a tab on the progress of WebDriver W3C Protocol.
In Selenium 4, WebDriver W3C Protocol replaces the older JSON Wire protocol. It essentially means that you no longer need to encode and decode the API request using the W3C protocol, and the tests can directly communicate with the web browser. The information will not be transferred by sending and receiving HTTP requests and HTTP responses, respectively.

As seen from the architecture of WebDriver W3C Protocol, there is a direct information exchange between the client and server, without the need for the JSON Wire Protocol. As Selenium WebDriver and web browsers use the same protocol, automated Selenium testing will execute tests more consistently between different browsers. Flakiness in web automation can be considerably reduced if a standard protocol is used.
With WebDriver W3C Protocol in action, automation testers would no longer need to change the automation test scripts to work across different web browsers. Stability and Consistency in tests are the two significant advantages of WebDriver W3C protocol in Selenium 4.
This Selenium WebDriver Tutorial for beginners and professionals will help you learn what’s new in Selenium 4 (Features and Improvements).
Major Advantages of the WebDriver W3C Protocol
The introduction of WebDriver W3C protocol offers several advantages, including the following:
- The automated Selenium testing will run more consistently across browsers as the browsers, and Selenium WebDriver is using the same protocol.
- With WebDriver W3C Protocol, automated Selenium testing will be less flaky and more stable. Stability in tests is a major reason to shift to Selenium 4.
- Actions API in WebDriver W3C Protocol are richer in comparison to the one in JSON Wire Protocol. The Actions API is revamped to conform with the WebDriver Spec. Action APIs would now let you perform multi-touch actions, zoom-in, zoom-out, pressing two keys simultaneously, and more. For example, the Pinch-zoom sequence in W3C Protocol is represented by an action sequence consisting of three ticks and two-pointer devices of type-touch.
- Standardization of W3C opens up opportunities for promoting compatibility beyond WebDriver API implementations.
- Websites with W3C compliance help in reducing the maintenance efforts, as cleaner code results in improved readability.
However, the native support for Opera and PhantomJS is removed since the WebDriver implementations for these browsers are no longer under development. The fallback option for Opera users is the Chrome browser, as the Opera browser is based on Chromium. For PhantomJS, users should use Firefox or Chrome in the headless mode. W3C WebDriver Protocol is one of the prime reasons to upgrade to Selenium 4!

Subscribe to CodingJag and get the best news around the testing world delivered to your inbox every Thursday morning.
Woo-hoo! Thanks for signing up for TestMu AI’s weekly newsletter!
JSON Wire Protocol vs. WebDriver W3C Protocol
The JSON Wire Protocol is marginally different from the WebDriver W3C protocol. Selenium 3.141.59 was the final Selenium 3 release, and it already had partial support for the newer protocol.

The JSON Wire Protocol was permanently retired in Selenium 4. The Selenium Changelog, published in the official Selenium GitHub repository, is a useful resource for tracking changes in Selenium WebDriver from a W3C compliance point of view.
The major difference is how a new session is created and how element interactions are performed using the Actions API. A look at the WebDriver W3C running document and now obsolete JSON Wire Protocol documentation shows that there are changes in error codes, data structures, and response status codes.
From a developer or automation tester’s perspective, in ideal scenarios, no changes are required in existing test scripts to make it run with the WebDriver W3C protocol.
Here is a brief list of the name changes across capabilities, proxy JSON Object, response status codes, error codes, etc. that come with W3C compliance in Selenium 4:
| JSON Wire Protocol | WebDriver W3C Protocol | Description |
|---|---|---|
| version | browserVersion | Browser version, which is a part of the browser capabilities. |
| platform | platformName | Platform or operating system the browser will be running on. |
| noproxy | noProxy | List the address for which the proxy should be bypassed when proxyType is set to manual. |
| UnknownCommand | unknown command | Requests could not be found, or the request was received using an HTTP method that is not supported by the mapped resource. |
| NoSuchFrame | no such frame | Desired frame to which a switch is performed is not found. |
| NoSuchElement | no such element | Web elements are not present on the page. |
| StaleElementReference | stale element reference | Command failed as the web element is no longer a part of the DOM. |
| ElementIsNotSelectable | element not selectable | Select operation cannot be performed on the desired web element. |
| JavaScriptError | javascript error | Error encountered when executing the JavaScript that is supplied by the user. |
| Timeout | timeout | Unable to complete the operation before the expiry of the timeout. |
| UnableToSetCookie | unable to set cookie | Requests for setting the cookie value cannot be satisfied. |
| NoSuchWindow | no such window | Command for switching to the desired window cannot be satisfied, as the Window is not found. |
| InvalidCookieDomain | invalid cookie domain | Illegal attempt to set a cookie under a different domain than the current page. |
| UnexpectedAlertOpen | unexpected alert open | Modal dialog is open, thereby blocking the current operation. |
| ScriptTimeout | script timeout | Script is unable to complete before the expiry of the timeout. |
| InvalidElementCoordinates | invalid coordinates | Coordinates supplied to the interactions operation are not valid. |
| SessionNotCreatedException | session not created | Unable to create a new session. |
| NoAlertOpenError | no such alert | Attempt for operating on a modal dialog box when it is not open. |
| MoveTargetOutOfBounds | move target out of bounds | Target that is provided to the move action is out of bounds. |
| stackTrace | stacktrace | An array of JSON objects that describe the stack trace for the exception thrown when the desired command failed. |
| InvalidSelector | invalid selector | Argument was an invalid Selector (XPath, CSS, Name, etc.) |
The W3C specification for WebDriver and now-obsolete WebDriver Wire Protocol is an excellent reference to keep an eye on the differences between both the protocols. The follow-up question that comes up after looking at discrepancies between JSON Wire Protocol and WebDriver W3C protocol is ‘What is the impact of WebDriver W3C protocol on existing test automation implementation’?
Impact of WebDriver W3C Protocol on an existing implementation
WebDriver W3C Protocol has been a part of Selenium since Selenium v3.8, but the Selenium WebDriver implementation stayed backward compatible with the JSON Wire Protocol until Selenium 4, where the JSON Wire Protocol was completely phased out. This means a team could already be using the WebDriver W3C protocol even while running tests on a Selenium 3 Grid. The final Selenium 3 release, Selenium 3.141.59, already had support for the W3C protocol, as shown in its own release history.
The changes are transparent to the developers and automation testers of the Selenium framework. The wire protocol level changes are supposed to enhance the API level owing to which tests would be less flaky and uniform across different browsers (and versions). For example, ChromeDriver version 75 onwards runs in the W3C standard-compliant mode by default. Developers and users of the Selenium framework had faced few issues with their tests, but the issue was fixed after updating the respective ChromeDriver.

Here are the screenshots of automated Selenium testing using ChromeDriver (version 86.0) executed on a local Selenium Grid (version 3.141.59). By default, it is using the WebDriver W3C protocol for communication.

Impact of WebDriver W3C Protocol on Automation Tests executed on TestMu AI
For users of the cloud-based Selenium Grid facilitated by TestMu AI, Selenium’s migration to WebDriver W3C protocol should not cause any impact. No changes are required in the existing automated Selenium testing scripts, as TestMu AI chooses the appropriate Selenium WebDriver protocol to work without hassles.
Here is a screenshot of a Selenium automation test executed on the cloud-based Selenium Grid by TestMu AI:

As seen in the screenshot, the WebDriver W3C protocol was used for automated Selenium testing.
You may also like reading Selenium Grid 4 Tutorial For Distributed Testing.
How Do AI Coding Agents Handle the WebDriver W3C Protocol in 2026?
AI coding agents such as GitHub Copilot, Cursor, and Claude Code write Selenium code against the WebDriver API, not the W3C wire protocol itself, because the Selenium language bindings already hide the HTTP and JSON exchange described above.
- API calls, not wire payloads: an agent asked to automate a browser generates familiar calls like driver.findElement and the Actions class. It never constructs a raw W3C request body, since the bindings translate those calls into the wire protocol on their own.
- CDP-based agents skip WebDriver: agent frameworks built for direct browser control rather than code generation, such as browser-use and the Playwright MCP server, drive the browser through the Chrome DevTools Protocol instead of W3C WebDriver, since CDP exposes lower-level introspection that the WebDriver spec leaves out on purpose.
- Legacy syntax risk: an agent trained on older Selenium material can still emit JSON Wire Protocol capability keys, like platform instead of platformName or version instead of browserVersion. A strict W3C-only Selenium 4 session rejects those keys instead of silently tolerating them, so the generated code fails until a developer corrects it.
Wrapping Up

WebDriver W3C protocol offers numerous benefits when compared to the JSON Wire Protocol. All the modern web browsers also use the W3C protocol, avoiding the need for API encoding and decoding in Selenium 4 (which uses the WebDriver W3C protocol). The issues that automation testers used to face when porting Selenium code from one web browser to another are now history with Selenium 4.
Selenium users get less flaky, more consistent, and more stable Selenium automation testing with the WebDriver W3C protocol in Selenium 4. The JSON Wire Protocol has been retired since Selenium 4 shipped, so a team's tests may already be using the W3C protocol even on a Selenium 3 Grid, since the WebDriver W3C protocol has been available since Selenium v3.8. The Selenium 3 implementation was backward compatible, meaning it fell back to the JSON Wire Protocol only where the W3C protocol was not yet fully supported.
To summarize, Selenium 4 features like W3C compliance have offered lasting benefits to the entire Selenium community, and Selenium 4 has been the stable, actively maintained release for years now.
Happy Automation Testing!
Author
Himanshu Sheth is the Director of Marketing (Technical Content) at TestMu AI, with over 8 years of hands-on experience in Selenium, Cypress, and other test automation frameworks. He has authored more than 130 technical blogs for TestMu AI, covering software testing, automation strategy, and CI/CD. At TestMu AI, he leads the technical content efforts across blogs, YouTube, and social media, while closely collaborating with contributors to enhance content quality and product feedback loops. He has done his graduation with a B.E. in Computer Engineering from Mumbai University. Before TestMu AI, Himanshu led engineering teams in embedded software domains at companies like Samsung Research, Motorola, and NXP Semiconductors. He is a core member of DZone and has been a speaker at several unconferences focused on technical writing and software quality.
Frequently asked questions
Did you find this page helpful?
More Related Blogs
TestMu AI forEnterprise
Get access to solutions built on Enterprise
grade security, privacy, & compliance
- Advanced access controls
- Advanced data retention rules
- Advanced Local Testing
- Premium Support options
- Early access to beta features
- Private Slack Channel
- Unlimited Manual Accessibility DevTools Tests










