Tools/testing-library/react-testing-library

React Testing Library

React DOM testing utilities

19.6k+3/wkgrowthJavaScriptMIT Licensenew this week

The Lens

By Erik Loyd, SaaS CEO and former COO/CFO of an AWS Premier Partner.

Updated Mar 2026

React Testing Library forces you to test your components the way users interact with them: clicking buttons, filling forms, reading text on screen. Instead of testing implementation details (state, props, lifecycle), you test what the user sees and does.

MIT licensed, created by Kent C. Dodds. This is the default testing approach for React. Create React App ships with it. The React docs recommend it. Most React job postings expect you to know it.

Fully free. It's an npm package. No paid tier, no service.

The catch: the philosophy is opinionated and that's the point. You can't easily test internal component state or mock child components, by design. If you're coming from Enzyme, the transition is a mindset shift. Some complex UI interactions (drag-and-drop, canvas, virtual scrolling) are hard to test with this approach. And for end-to-end testing (real browser, real clicks), you still need Playwright or Cypress. React Testing Library runs in jsdom, not a real browser.

Free vs Self-Hosted vs Paid

fully free

Fully open source under MIT. It's a testing library. Install via npm, use in your test suite. No cost, no service dependency, no enterprise tier.

Free. Industry-standard React testing library.

Self-hosting ops:trivial

Get tools like this every Wednesday

One featured tool, three on the radar. No fluff.

Similar Tools

Score
73/100 · B+
Adoption27/30
Maintenance10/25
Community11/20
License15/15
Analysis10/10

A low score is not a verdict on quality. Young and niche tools start low by design. How we calculate scores

Trust Signals

High adoption: 19,571 starsActive community: 1,157 forksPermissive license (MIT)

About

Stars
19,633
Forks
1,166

Explore Further

More tools in the directory