Next-Gen App & Browser
Testing Cloud

Trusted by 2 Mn+ QAs & Devs to accelerate their release cycles

Next-Gen App & Browser Testing Cloud

matches() DOM method

A method for determining whether a DOM element match a specific selector. Previously known as matchesSelector and widely supported with prefix.

Last updated on : 2023-03-20

Browser Versions

IEIE

EdgeEdge

FirefoxFirefox

ChromeChrome

SafariSafari

OperaOpera

5.5 - 8
Test on IE 5.5 - 8 ...
9 - 11
Test on IE 9 - 11 ...
12 - 14
Test on Edge 12 - 14 ...
15 - 111
Test on Edge 15 - 111 ...
2 - 3
Test on Firefox 2 - 3 ...
3.6 - 33
Test on Firefox 3.6 - 33 ...
34 - 113
Test on Firefox 34 - 113 ...
4 - 33
Test on Chrome 4 - 33 ...
34 - 114
Test on Chrome 34 - 114 ...
3.2 - 4
Test on Safari 3.2 - 4 ...
5.1 - 7
Test on Safari 5.1 - 7 ...
7.1 - 16.4
Test on Safari 7.1 - 16.4 ...
9.5 - 11.1
Test on Opera 9.5 - 11.1 ...
11.5 - 20
Test on Opera 11.5 - 20 ...
21 - 95
Test on Opera 21 - 95 ...

...Fully Supported

...Partially

...No Support

Specifications

DOM Standard # ref-for-dom-element-matches①

Syntax

var result = element.matches(selectorString);

Browser Compatibility

matches() DOM method on IE is partially supported on 9-11, and not supported on 5.5-8 IE versions.

matches() DOM method on Edge is fully supported on 15-111 and partially supported on 12-14 Edge versions.

matches() DOM method on Firefox is fully supported on 34-113, partially supported on 3.6-33, and not supported on 2-3 Firefox versions.

matches() DOM method on Chrome is fully supported on 34-114 and partially supported on 4-33 Chrome versions.

matches() DOM method on Safari is fully supported on 7.1-16.4, partially supported on 5.1-7, and not supported on 3.2-4 Safari versions.

matches() DOM method on Opera is fully supported on 21-95, partially supported on 11.5-20, and not supported on 9.5-11.1 Opera versions.

matches() DOM method on Safari on iOS is fully supported on 8.1-16.4, partially supported on 4.2-7, and not supported on 3.2-3.2 Safari on iOS versions.

matches() DOM method on Android Browser is fully supported on 97-111, partially supported on 2.3-4, and not supported on 2.1-2.1 Android Browser versions.

matches() DOM method on Opera Mobile is fully supported on 64-73, partially supported on 11.5-12, and not supported on 10-11 Opera Mobile versions.

matches() DOM method on Chrome for Android is fully supported on all Chrome for Android versions.

matches() DOM method on Firefox for Android is fully supported on all Firefox for Android versions.

matches() DOM method on Samsung Internet is fully supported on 5-20 and partially supported on 4-4 Samsung Internet versions.

100
Hightooltip

Overall Browser Compatibility Score

Note:matches() DOM method shows a browser compatibility score of 100. This is a collective score out of 100 to represent browser support of a web technology. The higher this score is, the greater is the browser compatibility. The browser compatibility score is not a 100% reflection for every browser and the web technology support. However, it does give you an estimate on how much you should rely on a particular web technology in terms of browser compatibility.


Test on 3000+ browsers for matches() DOM method & more

Test your website for matches() DOM method and other web technologies. Get 100 FREE automation test minutes!

Test Now...

KaneAI - Testing Assistant

World’s first AI-Powered E2E testing agent.

...
ShadowLT Logo

Start your journey with LambdaTest

Get 100 minutes of automation test minutes FREE!!

Signup for free

Did you find this page helpful?

Helpful

NotHelpful