Regex101 vs. Regexr vs. RegexTester – Battle of the Regex Testers

There are some grand tools online these days that allow you to write and test just about any regular expression out there using color coding, code explanation, substitution, etc. In this post, we make a thorough comparison of three regex tester tools: Regex101, Regexr, and RegexTester. Here’s a quick summary of the article:

The best regular expressions tester is Regex101 since it boasts the most features and supports the most language flavors. Regexr is a close second with a great design and modern feel. RegexTester is a wonderful minimalist tool with all the basic features you need. All three tools are easy to learn and use.

For comparison and screenshots, I’ve chosen a simple expression (for matching a particular date format) that I can test on all three tools. You can see the expression in action on Regexr and Regex101.

/(\d{4})\/(0[1-9]|1[0-2])\/(0[1-9]|[12][0-9]|3[01])/Edit with Regexity

So let’s dive right in and start the comparison with a quick background on each!

Background

Regex101 was started by Firas Dib as a hobby more than 10 years ago and grew into a full-featured Regex testing utility with a community of supporters and testers. It is currently closed-source and the developer has no plans of making it open-source anytime soon.

Regexr is an open-source regex tester created by Gskinner, a digital creative studio. This site has become one of the most popular regex-related sites and is often the first result that comes up when searching for regex.

RegexTester is part of a group of tools called Dan’s Tools that perform a variety of developer-oriented services online. An identical site is also found at RegexPal.com, which is also part of Dan’s tools.

Core Features

For developers, the features of any tool are undoubtedly a big factor when choosing a piece of software. Here’s a table of core features supported by all three tools, followed by an explanation of each.

  Regex101 Regexr RegexTester
Code explanation (tooltips) Yes Yes Yes
Code explanation (details) Yes Yes  
Syntax highlighting Yes Yes Yes
Math highlighting Yes Yes Yes
Flag settings Yes Yes Yes
Show number of matches Yes Yes Yes
Substitution Yes Yes Yes
Save regex Yes Yes  
Share regex Yes Yes  
Unit testing Yes Yes  
Details of matched groups Yes Yes  
Community expressions Yes Yes  
Code generator Yes    
Debugger Yes    
Language support Yes    

1. Explanation of Expressions

All three tools generate a great explanation of your code through tooltips as you mouse over portions of your code.

Regex Code Explanation via Tooltip
Regex Code Explanation via Tooltip

In addition, Regex101 and Regexr create beautiful list-style explanations that certainly help in better understanding your code. RegexTester does not have this feature.

Regex Code Explanation List (Regex101)
Regex Code Explanation List (Regex101)

2. Syntax & Match Highlighting

All three tools have excellent syntax highlighting, making it very easy to discern between different parts of the expression. For instance, groups are highlighted in green, quantifiers in blue, and ranges in orange.

Regex Syntax Highlighting (RegexTester)
Regex Syntax Highlighting (RegexTester)

Match highlighting makes it easy to see different matches that your expression matched in the search string. All three tools have this capability. However, Regex101 goes one step further by highlighting different matches in different colors. When using the PCRE (PHP) language flavor, it even highlights each capture group as a different color, which is a wonderful addition.

Regex Match Highlighting (Regex101)
Regex Match Highlighting (Regex101)

3. Flag Modifier Settings

All three tools feature flag modifier settings, although to various degrees. Regexr offers 6 flags for both Javascript and PCRE. Regex101 offers 6 flags for Javascript and 11 flags for PCRE. RegexTester offers 3 flags each for Javascript and PCRE.

4. Substitution Feature

Regex is very often used to replace certain parts of a match or build up a new string using substitution. It is therefore important that a tool has this feature available for testing. All three tools reviewed here has a substitution feature available, with more-or-less the same capabilities.

Regex Substitution (Regex101)
Regex Substitution (Regex101)

5. Saving and Sharing Expressions

In Regex101 and Regexr, saving an expression is as easy as clicking Save or using a keyboard shortcut. They will even allow you to save an expression without being logged in (although logging in will tie the expression to your account for easy locating later on).

They also provide you with a shortened url for easy sharing of the expression and replacement text with others.

RegexTester seems to have a saving feature, although I could not get it to work during my round of testing.

6. Unit Testing

Both Regexr and Regex101 offer unit testing capabilities, in which you can specify certain tests that must pass or must fail using the expression. This is extremely useful if, in testing an email expression, you have a list of valid email addresses and another list of invalid addresses.

Unit Tests (Regexr)
Unit Tests (Regexr)

7. Library of Community Expressions

Both Regex101 and Regex provides a searchable library of expressions submitted by community members that helps you to get started fairly easily with a basic idea for an expression. Both have a voting feature so other users can vote expressions up or down to surface the best ones.

RegexTester has a library of expressions but it appears to be created by the developer.

8. Details of Match Groups

Each of the tools provide details about matched groups that were found in the expression, including the match group number and the contents. All of the tools display this information as a tooltip when hovering over different parts of the expression, while Regexr and Regex101 also display these as a separate list in the sidebar or bottom bar.

Match Details (RegexTester)
Match Details (RegexTester)

9. Additional Features

Regex101, being the most feature-rich of the three, has a few additional features for power users that really make it stand out.

  • The first is a handy code generator that takes the regular expression you’ve created and creates a block of code that will run the expression. You can choose from a variety of programming languages.
  • It also has a nifty debugger (though only for PCRE or PHP) which allows you to trace through the regex engine’s steps and see where your expression might be failing.

Supported Regex Flavours

Each of these tools support a variety of regex flavours. Here’s a table that shows each one’s supported languages at the time of writing.

  Regex101 Regexr RegexTester
Javascript Yes Yes Yes
PCRE Yes Yes Yes
Python Yes    
Golang Yes    

Design

All three tools feature a very well-thought-out design. Regexr’s design seems more modern and sleek, with a designer’s hand clearly visible throughout.

Regexr Screenshot
Regexr Screenshot
RegexTester Screenshot
RegexTester Screenshot
Regex101 Screenshot
Regex101 Screenshot

Regexr and Regex101 are both responsive and viewable on mobile. RegexTester will still work on a mobile device but the layout is not responsive.

Customer Support

Both Regexr and Regex101 have communities on Github where users can record issues. However, Regex101’s repository seems to be much more active, and the development team is much more responsive than on Regexr’s repository.

Popularity

Google Trends has this to say about the popularity of each tool in search. Regexr and RegexTester have had a fairly consistent search volume over the past 5 years, while Regex101 has grown over time. All three tools seem to have taken a dive during the 2020 pandemic.

Regex Testers - Google Trends
Regex Tester Comparison – Google Trends

Advertisements

All three of these tools are free to use for everyone! As far as I can tell, none of them have a paid tier. However, all of them make use of ads in some form or another.

  • Regex101 allows sponsorships and then places a small logo and link in the bottom left-hand corner. Non-obtrusive and barely noticeable if you’re not paying attention. They also have a donate button for those that appreciate the tool.
  • Regexr displays Carbon ads in the bottom left corner, which are pretty much developer-oriented. If you are using a site like Regex, chances are pretty good you’re going to benefit from seeing these types of ads.
  • RegexTester makes use of Google Adsense ads, which is often not a good idea. A flashing ad can become really distracting when you are trying to focus on the task at hand (regex is not easy). Any free adblocker should do the trick, however.

Conclusion

Each of the three tools has its pros and cons.

If you’re looking for a minimalist approach, RegexTester is your tool. For a well-designed and capable tester, go for Regexr. And finally, for a full-featured tool with support for various flavours, use Regex101.

Benjamin

Founder, owner, and sole content creator on RegexLand. Enjoys programming, blogging, and teaching others how to do the same. Read more...

2 thoughts on “Regex101 vs. Regexr vs. RegexTester – Battle of the Regex Testers”

  1. The only problem with Regex101 is it’s name.
    Maybe he started the project with intentions of the site being an “Intro To Basics” regex training site, but it’s grown far beyond that. At this point, a potential user of Regex101 needs to have some prior understanding of Regex or that site will not make a bit of sense. Even with an understanding of what RegEx does, a user still needs to fiddle around with that site, making sure the correct stuff is selected so that it will act as expected.
    I’m just saying, even this review article is raving about how advanced RegEx101 is…. advanced doesn’t belong in 101 class. lol

    Reply

Leave a Comment