TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

RegExr: A website for interactive regex prototyping with syntax highlighting

384 pointsby sconxuabout 10 years ago

31 comments

jasodeabout 10 years ago
Unfortunately, RegExr does not color-code the different capturing groups.<p>For example, replace the RegExr sample regex with &quot;([A-Z])\w+\s\w(\d.\d)&quot; and compare[1][2] its color coding capability to the other regex helpers.<p>The other sites such as regex101.com &amp; debuggex.com will delineate the capture groups within the matched text using different colors. This is very helpful for complex captures because making the boundaries visible can reveal bugs in your thinking of what substrings the regex is actually capturing.<p>(I don&#x27;t intend to be negative. If capture group color-coding is an easy coding enhancement for RegExr, consider my comments as mentioning a minor nit.)<p>[1]<a href="https:&#x2F;&#x2F;regex101.com&#x2F;r&#x2F;eB5jY1&#x2F;1" rel="nofollow">https:&#x2F;&#x2F;regex101.com&#x2F;r&#x2F;eB5jY1&#x2F;1</a><p>[2]<a href="https:&#x2F;&#x2F;www.debuggex.com&#x2F;r&#x2F;mci3WLNmHGTEatf6" rel="nofollow">https:&#x2F;&#x2F;www.debuggex.com&#x2F;r&#x2F;mci3WLNmHGTEatf6</a><p>(couldn&#x27;t find a way to enable &#x2F;g global on debuggex.com (even tried PCRE option) but color boundaries still show up on the 1st capture group)
评论 #9583609 未加载
评论 #9581741 未加载
mraisonabout 10 years ago
Nice work :) Looks like this tool puts the emphasis on the pedagogical aspect.<p>For development, the most fantastic tool that I know of in this space is debuggex. Here is an example with roman numbers:<p><a href="https:&#x2F;&#x2F;www.debuggex.com&#x2F;r&#x2F;Xqlv3QcAuw_EgPSM" rel="nofollow">https:&#x2F;&#x2F;www.debuggex.com&#x2F;r&#x2F;Xqlv3QcAuw_EgPSM</a>
评论 #9581677 未加载
评论 #9582320 未加载
评论 #9581562 未加载
评论 #9581526 未加载
rcaughtabout 10 years ago
My favourite is still <a href="https:&#x2F;&#x2F;regex101.com" rel="nofollow">https:&#x2F;&#x2F;regex101.com</a><p>Example regex: <a href="https:&#x2F;&#x2F;regex101.com&#x2F;r&#x2F;wY0rM7&#x2F;1" rel="nofollow">https:&#x2F;&#x2F;regex101.com&#x2F;r&#x2F;wY0rM7&#x2F;1</a>
评论 #9581491 未加载
评论 #9581573 未加载
评论 #9583329 未加载
chdirabout 10 years ago
I had the older version bookmarked <a href="http:&#x2F;&#x2F;gskinner.com&#x2F;RegExr&#x2F;" rel="nofollow">http:&#x2F;&#x2F;gskinner.com&#x2F;RegExr&#x2F;</a> which now redirects to this site. Some other good sites that I&#x27;ve used are:<p><a href="http:&#x2F;&#x2F;regviz.org&#x2F;" rel="nofollow">http:&#x2F;&#x2F;regviz.org&#x2F;</a><p><a href="https:&#x2F;&#x2F;regex101.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;regex101.com&#x2F;</a><p><a href="http:&#x2F;&#x2F;osteele.com&#x2F;tools&#x2F;rework&#x2F;" rel="nofollow">http:&#x2F;&#x2F;osteele.com&#x2F;tools&#x2F;rework&#x2F;</a><p><a href="http:&#x2F;&#x2F;www.rexv.org&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.rexv.org&#x2F;</a><p><a href="https:&#x2F;&#x2F;www.debuggex.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.debuggex.com&#x2F;</a>
评论 #9581853 未加载
评论 #9582141 未加载
nodesocketabout 10 years ago
RegExr looks really nice, but my go to is still <a href="http:&#x2F;&#x2F;rubular.com" rel="nofollow">http:&#x2F;&#x2F;rubular.com</a>.
评论 #9581316 未加载
romankolpakabout 10 years ago
I have been a regular user of this website for quite some time now. I like the UI and usability is great.<p>Also, <a href="https:&#x2F;&#x2F;regex101.com" rel="nofollow">https:&#x2F;&#x2F;regex101.com</a> is very good alternative
notlistedabout 10 years ago
My favorite tool for quick regex definition to text extraction is <a href="http:&#x2F;&#x2F;txt2re.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;txt2re.com&#x2F;</a><p>Paste a sample line, mark the parts you like, it generates a piece of code to extract just those parts. Has saved me hours.
jbrooksukabout 10 years ago
RegExr is my go to regular expression playground. I&#x27;ve been using it for many years, back when it was on <a href="http:&#x2F;&#x2F;gskinner.com&#x2F;RegExr" rel="nofollow">http:&#x2F;&#x2F;gskinner.com&#x2F;RegExr</a><p>It&#x27;s evolved a lot since then :)
euan_toranoabout 10 years ago
For anybody doing .NET development, RegexHero (<a href="http:&#x2F;&#x2F;regexhero.net&#x2F;tester" rel="nofollow">http:&#x2F;&#x2F;regexhero.net&#x2F;tester</a>) is nice. It uses Silverlight though...
janfoehabout 10 years ago
Will be bookmarked alongside my other regex helpers.<p>One of my other favourites: <a href="https:&#x2F;&#x2F;jex.im&#x2F;regulex" rel="nofollow">https:&#x2F;&#x2F;jex.im&#x2F;regulex</a> , a regex visualizer.
amenghraabout 10 years ago
<a href="http:&#x2F;&#x2F;regexp.quaxio.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;regexp.quaxio.com&#x2F;</a> tries to act as a linter.
评论 #9581860 未加载
verytrivialabout 10 years ago
I&#x27;ve been programming for about two decades. I had composed three regexes before my first coffee and before seeing this article this morning. My problem: I <i>still</i> don&#x27;t have a good mnemonic to remember how magic differs grep, egrep, vim, awk, Perl, Python, etc. If that this site had modes and flavoured cheat-sheets I would live there!
评论 #9581478 未加载
teddyhabout 10 years ago
<p><pre><code> emacs M-x regexp-builder</code></pre>
Elracabout 10 years ago
Sorry if this information is visible somewhere: Which dialect of regexp does RegExr &quot;do?&quot;<p>In the past, when I&#x27;ve looked for a good Internet RegEx test site, I&#x27;ve had trouble finding one that &quot;does&quot; the Java dialect.
vbezhenarabout 10 years ago
What I am missing is some kind of service to convert between different types of regexes. Like Java, Intellij Idea Search&amp;Replace, vim, less, grep, egrep, sed. There are subtle (and sometimes not so subtle) differences between them which I always forgetting and have to trial&amp;error a bit.<p>I wish there would be one single standard to regexes. Great tool but difficult to use because of many incompatible implementations.
alexcasonabout 10 years ago
I&#x27;ve been using RegExr for years, it&#x27;s the first place I go to when I have a tricky regular expression to put together. It works really well.
kachhalimbuabout 10 years ago
My favorite is regulex[1] a visual explanation of regex<p>[1] <a href="https:&#x2F;&#x2F;jex.im&#x2F;regulex" rel="nofollow">https:&#x2F;&#x2F;jex.im&#x2F;regulex</a>
评论 #9581471 未加载
hienchuabout 10 years ago
This is awesome, but I like <a href="https:&#x2F;&#x2F;regex101.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;regex101.com&#x2F;</a> more
gmacabout 10 years ago
Suggestion: allow use of extended regexps too (I have a quick JS function to enable this, which you can regard as public domain: <a href="http:&#x2F;&#x2F;blog.mackerron.com&#x2F;2010&#x2F;08&#x2F;08&#x2F;extended-multi-line-js-regexps&#x2F;" rel="nofollow">http:&#x2F;&#x2F;blog.mackerron.com&#x2F;2010&#x2F;08&#x2F;08&#x2F;extended-multi-line-js-...</a>).
pskabout 10 years ago
Sites like this is great and all, but I wish they included some commonly used regexes. Like a list of &#x27;good&#x27; regexs to validate phone numbers, emails and other common stuff.<p>It would actually be pretty cool to have a site like this except you could add the regex to a list, and then people could upvote the regexe depending on the quality of it.
评论 #9581462 未加载
评论 #9581340 未加载
评论 #9581353 未加载
gnrlbzikabout 10 years ago
I&#x27;ve been looking for something like this on mac since I moved away from windows long time ago, no RegEx Buddy, such a great tool too. I think that I discovered regexr a year ago. This is such a great tool. Much appreciated work from @gskinner and community.
crdoconnorabout 10 years ago
I&#x27;ve tried a number of these and this is the one I&#x27;ve gotten along with best:<p><a href="http:&#x2F;&#x2F;jsregex.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;jsregex.com&#x2F;</a><p>Simple, minimalist, takes up all available space in the viewport &amp; also works offline if you save the page.
thomasflabout 10 years ago
I really like the regexp syntax coloring. What makes me still reach out for rubular.com, is actually the regexp cheat sheet on the bottom of the page. After 25 years, I still like to have a cheat sheet for regexp to remember all the swithces etc.
XorNotabout 10 years ago
Probably my favorite tool on the internet. One thing I wish it had was an implicit select option like grep -o since I frequently find myself using it to do interactive text manipulations for one offs.
raneabout 10 years ago
<a href="http:&#x2F;&#x2F;refiddle.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;refiddle.com&#x2F;</a> is a similar service I&#x27;ve found useful.
kyberiasabout 10 years ago
Is there a service that would allow one to enter positive matches and negative matches and it would then deduce a regex suggestion for that?
nathancahillabout 10 years ago
My favorite for Python is still <a href="http:&#x2F;&#x2F;www.pyregex.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.pyregex.com&#x2F;</a>
paradox95about 10 years ago
This has been my go to regex testing site for years. Absolutely love it.
r4phaabout 10 years ago
Cool! These are the same guys behind CreateJS. Amazing work as well.
alzabout 10 years ago
this has been posted a few times, but is a great resource
anon3_about 10 years ago
Author:<p>- When did you begin this?<p>- What front-end JS framework did you program this in?<p>- How many visitors do you get per day?
评论 #9581638 未加载
评论 #9581407 未加载