RegExr: Free Online RegEx Testing Tool

RegExr is an online tool for editing and testing Regular Expressions (RegExp / RegEx). It provides a simple interface to enter RegEx expressions, and visualize matches in real-time editable source text. It also provides a handy RegExp snippet sidebar with descriptions and usage examples to make it easier to learn Regular Expressions through trial and error.

It isn’t as powerful as a product like RegExBuddy, but it has the advantage of being online and free. I will be releasing a free desktop version for Mac OSX and Windows built with AIR in the next day or two.

So far this has only taken a day of development, and the main app is only 150 lines of code. Flex 3 makes this kind of app so darn simple to put together.

RegExr is built with Flex 3, and uses ActionScript 3’s built in RegExp engine. As with most engines, the AS3 RegExp implementation isn’t perfect, so you are likely to encounter some limitations and oddities. Likewise, RegExr is very much beta software (did I mention it was developed in a day?), and currently has no error handling whatsoever, so it’ll probably have a few quirks of its own.

RegExr uses an extension of the TextHilighter class that comes with the Spelling Plus Library. We will be including the RegExpHighlighter class with a future release of SPL.

If you encounter any issues using RegExr, would like to request a feature, or have a snippet you’d like to see added to the snippets pane, leave a comment below.

Here’s a quick screen shot of RegExr in action.

The latest version of RegExr will always have a permanent home at: Flash Player 9 is required. I hope this is useful to people!

Update Mar 27, 08:

0.1.2b is online. Please click here to read about the update.

Update Mar 31, 08:

0.1.4b is online, and the desktop version of RegExr is now available. Please click here to read about the desktop version.

Update Mar 31, 08 (2):

0.1.5b is online, with support for replace functionality.

Update Apr 1, 08:

0.2.0b is online. I wrote a simple RegEx lexer for this version, so it understands your expressions at the token level. It still has a couple of minor quirks (character ranges with escaped characters is the main known issue [\x41-\x48] ).

Update Apr 2, 08:

0.2.1b is online. It addresses issues with character ranges and escaped characters, and includes some minor UI tweaks. Click here for more info.

Update May 26, 09:

0.3b is online. It allows you to save, share, search, and rate patterns. Click here for more info.

Grant Skinner

The "g" in gskinner. Also the "skinner".



  1. Very useful tool! Thanks.

  2. I made a similar application a while ago, you can see it at

    It has code highlighting and you can test with replace functions.

  3. Grant, this is very cool. Super useful, and I like the didactic aspects of the UI.

    One thing that would be useful would be to have an ‘auto-execute’ mode/checkbox so that you could see the matches change on every keystroke in the TextInput.

  4. Ids – nice work! I started writing a lexer, but didn’t finish it in the one day limit I gave myself (I’m currently procrastinating about doing my FitC slides). I hope to add similar functionality soon.

    Daniel – definitely in my plans. I just need to handle exceptions properly first. I don’t want the browser to crash because of a malformed expression.

  5. William from Lagos April 2, 2008 at 4:52am

    Hello Grant. Just wanted to inform you that your regex tool came in very handy when I most needed it. Thanks for your effort.

  6. Doubleclicking text in the pattern field seems a bit off. Can’t put a finger on exactly what, tho :)

    It would be nice to have some sort of hierarchical doubleclick action. I.e. first select a group, then a component of the group and last the set or quantifier of the selected component.

  7. Great tool, there’s nothing worse than trying to do ReGex without a scratch pad to work out whether they work okay or not – that’s just what this is. I downloaded the Adobe AIR version and will use it regularly, I guarantee.

  8. Hello, nice tool. It will be nice to see it on Russian. Can I help you to translate?

  9. In the desktop version it would be nice to be able to save your expressions, perhaps along with the examples to the right.

  10. Thanks for the great job you have done. That is one “kick-ass” tool. Thanks again.

  11. Hi this is great, RegEx expressions can get way confusing, but your app sure makes things easier. If I may ask for your advice though via an example-

    If I wish to strip bracket characters such as * () [] “” etc from a string using one RegEx pattern, what would the RegExp look like? I can successfully replace one at a time with your tool, using \* but if I add something like \*\( it doesn’t replace anything.

    Thanks, really great AIR app as well.

  12. Sorry it is me again, with regards to my last post about the mutliple replace in one RegExp, I have the solution which you may like to work into your next release.

    To replace * and () in one expression use:

    /(\*|\(|\))/gi. Perhaps when a further expression is added via your app you could somehow insert the | and enclosing brackets to make the replace work.

    Thanks, JP.

  13. Hello Grant,

    Excellent initiative! I’m looking forward to using it!

    I’ve tested sofar:

    Expresso Regular Expression Development Tool

    by Ultrapico. It is pretty advanced (too much ?) and might be inspiring for your own tool?

  14. Hi Grant,

    Thanks for putting this out there! After a couple years of false starts, it’s really helped me finally figure out regular expressions. I would like to second tan’s suggestion to add the ability to save patterns to the sidebar in the AIR version.

  15. Air version needs unrestricted access to computer ???


  16. There is no option to copy the matched result.


  17. Very handy tool, but it showing the text as like whole pattern matching, while explanation showing right things.

    Try this RE:


    And any text that contains URL’s. It should match URL right after it’s end, before any dots, pipes, quotes etc.

    Explanation is right:

    RegExp: /\b((?:http|ftp)://[^\s\”\’]\S+?)(?:[\,\.\|\)\>\’\”]?(?:\s|$))/gi

    pattern: \b((?:http|ftp)://[^\s\”\’]\S+?)(?:[\,\.\|\)\>\’\”]?(?:\s|$))

    flags: gi

    1 capturing groups:

    group 1: ((?:http|ftp)://[^\s\”\’]\S+?)

    But I just spotted a minor error.


    RegExp: /\b((?:http|ftp)://[^\s\”\’]\S+?)(?:[\,\.\|\)\>\’\”]?(?:\s|$))/gi

    It should either select alternative chars to mark start-stop (i.e. # or !), or escape “//” in middle.

  18. AnrDaemon,

    I’m not sure I understand the issue. There is a possible problem with your expression, in that it matches characters at the end it probably shouldn’t. Notice below I have changed the trailing non-capture group to a forwards look around instead.


    You did make me notice a problem with my RegExp Lexer where it doesn’t deal with escaped closing brackets properly. I’ll try to fix that.

  19. Very cool tool. It would be great if it is able to generate code like php, perl and C#. Check out this online tool ( It can generate php code. This feature is really useful.

  20. I found a small bug:

    If you enter a positive lookbehind (?

  21. hi. great tool to play around with :)

    but i’m running in some problems/questions here: i’m trying to get the text between two html-tag – without the tags!

    <a href=’asdasd’>text</a>

    should return “text”

    i’m not so much into regex – the one i’m trying is:




    hope this’ll show up correctly in the browser ..!?

    maybe someone can help me … what am i doing wrong. or is the positive lookbehind not working properly?

    thanks, phil

  22. Phil – have you tried using the snippet to do this from the samples list (in the right side bar)? It’s the second one from the bottom in that list. You may have to tweak it for your specific needs, but it handles the example you posted nicely.

  23. thanks grant … didn’t see that one 😉

    will try to change the snippet to my needs.

  24. Thank you a lot Mister Skinner!

    The only thing it lacks is the ability to show the text and regExp that were in the fields at the moment when I close the app.

    I hope there will be such a feature in the next version (if there’s going to be one) :)

  25. Great app! Thank you Mister Skinner.

    It only misses one thing – the ability to remember the content of the fields which were just before I close the app. It’s a bit annoying to paste the text and regExp each time you start a work with it.

  26. This is an amazing tool! Thank you a lot Mister Skinner.

    The only thing it lacks is the ability to “remember” all the texts there were in the fields just before the app is closed.

  27. Unrestricted for AIR version?

    No thanks.

  28. Fred,

    This is a standard message on the AIR application installer. It merely indicates (in a rather dramatic way) that it will have the same access to your system that any other desktop application has. Adobe just feels the need to warn you about it, whereas other desktop application installers do not.

    Cheer, Grant.

  29. i was writing yet another regex at work today utilising this app which reminded me what a great user experience it provides integrating the logic development, syntax checking, and case testing into a single clean interface! very “regexbuddy” lite … if only there were a version for e4x 😉

  30. I’ve been using RegExr for a while and just have to say Thanks! It is awesome.

    – Rory

  31. Great tool Grant – thanks

  32. Hi Grant,

    I’ve been a fan of your work for quite some time now.

    Earlier this year, I was doing lot of regular expression work and upon searching the web, I didn’t find any good tools (this was before you posted regexr). In February I began building an application to rapidly create Flex regular expressions in a similar style to the ‘Explorer’ applications that exist for Styles and Components.

    I had it 95% complete by May, but had to put it on the back burner. Later in the summer, a friend of mine sent me a link to your application which I have found to be a quality tool, as I certainly expect from you. But it has some different feature sets to the tool I was building, so I recently was able to wrap mine up and posted it yesterday.

    It is called the Flex 3 Regular Expression Explorer and can be found at my blog:

    I felt that providing an interpretive environment for rapidly creating regular expression was a great base feature set, but I really wanted people who don’t understand regular expressions to be able to get involved, so I added a full-featured contextual help panel. I also wanted to provide some basic examples that I came up with but also allow anyone else who uses the tool to be able to contribute their own creation as well to the community. When we all work together, we all profit, etc.

    Anyhow, I just wanted to send you a quick note and mention what a fan I’ve been of your work and to see if you had any feedback for the application I just released.



    See you at MAX!

  33. grapefrukt, philipp – yes, there’s a look behind behavior bug in EcmaScript 3 RegExp. This issue was committed to Adobe JIRA:

    and then has been marked as external and redirected to Mozilla’s Bugzilla:

    This doesn’t help us in solving the problem, but at least we know what’s the root of the wrong behavior.

  34. What regexp dialect is this for? Ecmascript’s?

  35. Regexr is a great tool, thanks for putting it together. Any change you could actually show the different groups captured? Thanks!

  36. Nick – if you roll over a match highlight (the blur round rectangles), it will dispay a tooltip showing the captured groups. Is that what you needed?

  37. I just wanted to say thank you! this is an awesome tool and has helped me learn Regular Expressions.

  38. regexr is great, but I noticed some inconsistencies when using the expressions in javascript on other browsers… so, I developed a similar tool that is native to javascript on the browser it is running… check it out (see my link)

    I hope this helps others too.

  39. I don’t know where to report the problem, so lets do it here…

    The entry field to enter the regex takes the AltGr key into account as if it was a character key, so that when I type “AltGr+(” to get the character “[“, the field will contain AltGr[ while AltGr stays invisible. I correct this by going one letter back and typing backspace.

    This is, under Linux with the Linux Flash version 10.

  40. Thanks so much for this. This editor is invaluable.

  41. Two bugreports and one request:

    – lookbehind is displayed as lookahead (highlighting help textwhen hovering over the regex part)

    – When matches are displayed, hovering over the match will show information about it. But it is impossible to click the match to position the cursor there.

    + Please allow oldschool keyboard shortcuts (CTRL+Ins = copy, Shift+Ins = paste, Shift+Del = cut).

    Using Opera 9.5 on Vista.

  42. Avétis KAZARIAN March 5, 2009 at 12:35pm

    I’m running a GNU/Linux x86_64 and I’ve got this error while trying to install the desktop version :

    “This application requires a version of the Adobe Integrated Runtime (AIR) which is no longer supported. Please contact the application author for an updated version.”

    Plus, as posted above, I’ve got an additional character when using AltGr : “” (char code 0x03)

  43. Avétis KAZARIAN March 5, 2009 at 12:54pm

    For the “additional character” it seems to be a problem with encoding : I’ve got some “é” etc. when trying some latin characters.

    Anyway, the tool works fine.

    Great job.

  44. Find ich echt Super! Gute Arbeit.

  45. Hey Grant. Great plugin, and especially great UI. I’d like to suggest one improvement: It would be great if your app also translated expressions into the proper regex syntax for various languages. I tried one of the other tools listed in these comments located at: and I was able to solve a problem that had plagued me for hours because I (a designer not developer) had no idea I was using improper syntax. RegExr is such a great teaching tool, this seems like it would be a perfect addition.

    Again, great app.

  46. Hey Grant. Need a save faechure

    and nice to see online loading and saving users regexp’s

    its easy to do and very helpful for endusers…

    waiting for updates

  47. How about unicode support in this app?

  48. Excellent tool. After hours of trying to get my regular expression syntax correct and failing, I searched for a regex tool and found yours.

    It is great!

  49. Awesome! And all the other goodies mentioned in the comments too – a RE Bonanza! Would be excellent if I could save my expressions to the APP. Would be super if input box supported Undo.

    Thank You!

  50. Hiya again.

    I already wrote to thank you for this cool tool. A request, if you ever revisit it: an option for a considerably larger font size. On my Mac, the text is VERY small for my aging eyes, and I guess, since it’s Flash, I can’t change the text size as I do for regular web pages. Thanks!


  51. Super! I’m using the web-application for a while now. Maybe a nice icon would make the lot a bit more nicer, no? 😉

  52. Hey Grant, very nice and usefull app, but could you please implement and auto-update version and maybe a small nice icon, a little bit easier to recognize on a Mac in a folder.

    Just a tip!

  53. Is anyone having trouble with the results portion of the app not displaying the regex result?

  54. Juan Hernandez May 29, 2009 at 8:27am

    I’m having problems too with the last update.

    It used to display multiple matches before but it doesn’t work now …. not even with things like [0-9]*.

    Is it possible to get the previous version?

  55. Igordon & Juan,

    If you’re able to reproduce these issues, please let me know and we’ll try to fix them. I can’t reproduce them here. Starting up RegExr online or desktop, and typing in [0-9] shows 3 results on the default text (0,3,3).

  56. Juan Hernandez June 2, 2009 at 10:19am

    Hi Grant,

    I’m not sure but I think the matches used to work slightly different (I don’t have the previous version so I cannot confirm it 100%).

    When putting an expression with the default text like (\w*) (to match all the words) only the first word is matched. I think like it was before it would have matched every word in the text.

  57. Juan,

    You’ll notice that \w* turns red, this is because it can match 0 characters, and get stuck in an infinite loop. If you change your search to \w+, which requires at least one character to match, you should see the result you are expecting.

  58. This is an awesome tool. Two things that may make a small improvement: the ability to be able to zoom in (make the text bigger), and the ability for sharing (in other words, having a URL that will auto-init the page with the data that I would like to share). Also, a dropdown to select the language in which the RegEx will be used (since not all languages support all of the RegEx capabilities).

    Other than that, this is my tool of choice now.

  59. On what software was the UI made?

  60. Exactly what I needed. Thanks!

  61. Really lovely thing. But I wanted a desktop version I failed to install on Intrepid Ibex and Jaunty Jackalope latest updated version of Ubuntu Linux. the RegExr.Air file doesn’t download at all. Even if it downloads then Adobe AIR installer says its corrupted.

  62. This is an amazing tool, really awesome! Just what I was looking for. Looking forward to any updates. Thank you very much!

  63. Very useful tool. And when something won’t work, it helps! XD

    Last time I’ve used? Regular expressions in .htaccess file (for mod rewrite) 😛

  64. Just found out about this via a Google search that found a entry about it.

    Wanted to say thanks for an awesome tool. I may finally get the hang of regular expressions with this! :-)

  65. Thank you very much for this!! Magnificent tool and AIR app.

  66. I figured out how to replace a matched string with the new string I specify. BUT how do I use the replace function to use the string that matched.

    For instance:

    (412) 567-7889, (412) 567-7882


    +1 (412) 567-7889, +1 (412) 567-7882

    Or, and I cannot imagine why I would want to do it but

    (412) 567-7889, (412) 567-7882


    Please call(412) 567-7889 to speak to the doctor, Please call (412) 567-7882 to speak to the doctor

  67. Ok I saw how to use the matched string in the replacement: $&

  68. Amazing tool! superb!

  69. Like “john” said 4 months ago, undo for the input box would be great. While working on an especially tricky expression, I think I managed to reach for the currently nonexistent feature at least 3 times in one minute :)

    But apart from that, RegExr is great. 😀


  70. Seems the standards for this have not been updated. I am looking for case-insensitive checking, to keep my expression as small but have the same utility as my others.

    Current form:


    New Standards form:


  71. Awesome tool. It helped me a lot when I decided to learn RegExp

  72. so nice app man!!!

    perfect! Are the any flash exe file that we dont need to install anything else and use offline??

  73. Just wanted to say thanks for the great work. This is a life-saver.I work in a government org where our PCs are really locked down (unfortunately not for any glamorous reason–our IT dept is just really intrusive), so I can’t install 3rd party apps like RegexBuddy. But they can’t keep me from opening up my browser!

  74. WOW! That’s awesome. Makes it so easy, no need to wonder anymore “where did I miss a dot?”.

    Thanks a million for this software :)


  75. Maravilhoso, acho que é a melhor formar para testar expressões regulares! Parabéns!

  76. Adrian Gallardo November 5, 2009 at 9:07am

    Good job!!, It’s a very usefull tool!!!

    You could improve it by adding an option to save customs expresions into external files, so then you can load them in other PC, or something like that..

    Thank you a lot!! Adrián (from Argentina)

  77. Excellent tool

  78. it is very usefull.

    thanks a lot…

  79. HI everyone,

    Need your help here

    That tool is helpfull, but I cannot resolve my problem

    This is my string :

    NSD-IN.prv one two three ce test consiste a trouver des NSD occurences nsd de span a l’interieur des href. bla NSD-IN.prv

    NOW I am trying to match all occurences of “NSD” but not within the tag

    THis matches my exclusion : ]*>(.*?)

    How can I use it with combinaison of (NSD)


  80. it is a very nice and comfortable tool. i liked it.

    thanks alot.


  81. December 17, 2009 at 8:59pm

    Thank you so much!!! very great and friendly tool to learn the unfriendly yet powerful regular expression!

  82. Great Tool! but how i’ll find the Expression for the following :

    1) 1/1

    2) 1/1/1

    3) 1/1/1/1

    Consider 1 as decimal and it should satisfy all three conditions. Can anyone help me.

  83. Hi

    I found a bug.

    The Regexp “(.)$1” in the textbox does not match “aa” in the textarea. Surely it should. This affects both the online version and the AIR one. I suspect that this was a bug introduced in an update as your second last Sample Regexp for “matching text that is not part of a HTML tag” also fails and I’m sure you tested it but may have overlooked during updates.

    I hope you fix this – its a great teaching tool.



  84. Anand Hariharan January 9, 2010 at 11:18pm

    Thank you much for providing an online editor that provides RE functionality. This satisfies a much needed niche.

    I found a bug: Character classes that need the closing square paren viz., the ‘]’ character is not supported.

    I have tried –

    []] as well as [\]]

    – to no avail.

  85. how to find the Expression for the following :

    1) 1/1

    2) 1/1/1

    3) 1/1/1/1

    Consider 1 as decimal and it should satisfy all three conditions. Can anyone help me.

  86. Jonathon Reinhart January 27, 2010 at 4:00pm

    Great Tool! I love it!

    I found a slight bug: The lookbehind’s are incorrectly labeled lookahead’s when you hover over them in the regex input box.

    Thank again!

  87. Wonderful tool. I use the online version whenever I am doing Perl regexp programming to save time.


  88. First… I love this tool. I am adding it to my list of the “best free resources online”.

    Two… Where is the donate button?

    Three… Give us the ability to comment on comments, or start a forum!

    Four… Please change the blog sort-order so new posts are first.

    Fifth… Would be great if we could save our “testing data” too… not just the formula. (Though, for others submissions, that would not immediately display, for reasons of spam. But it would be available so we can see how through the code is, and possibly submit “failures” or suggestions by linking to a custom “comments” page.)

    Sixth… It would be SUPER if you could setup “COLOR MATCHING” to indicate which characters matched each appropriate condition as a selectable option. (Possibly even show the matching combo when we mouse-over that color in the found-text.)

    EG… showing that /a[tpg]e/ matches ape by highlighting the ‘a’ blue in the code and text, the p yellow, the e green… or for the formula, the entire [tpg] might be yellow, showing you where, not the exact condition.

    NOTE: Seems that the program has a hard time identifying “\/” as an escaped “/”, though it pairs it correctly and has the definition in the box on the right-side. (Might be because you are escaping it as “\\\/” in the code, so it can’t match correctly? or it is escaped as “\\/” since the real code in the program that identifies, may not need to escape the “/”, just the “\”.

  89. Grant, just downloaded the AIR version (because Safari and FP 10.1 don’t like each other and I don’t like FF that much).

    Anyway, a tiny little feature request that bugs me nonetheless: Please save the window size in the AIR app. It drives me crazy 😉

    Love love love your very useful RegEx tool!! (and it made me finally appreciate RegEx)

  90. very useful tool, thank you :)

  91. You have no support of:

    a{,5} !!! only a{0,5}

    you have no support of






  92. Hello.


    replace not working with $1 – returns $1 but not a first capture.

  93. gimcnuk – I just tested this, and it seems to work fine. Perhaps there was a problem with your expression? To test, launch RegExr, click the replace tab, and change the replace expression to use $1 instead of $&. You should see the correct results in the output.

  94. Hi,

    This is a great tool, but is there a way to insert escaped characters in the replacement string. For example, is there a way to replace something with “\n$1\n”?


  95. Sorry, I forgot to add another example such as replacing something like “resume” with “resum\xE9”.

  96. The desktop version of RegExr runs afoul of Norton Internet Security 2010’s behavioral malware detection feature (called SONAR).

    I’ve had the same problem with one other AIR app that I knew was harmless: Dwarf, a screen ruler program from Jonnie Hallman of Perhaps the two of you could work together to figure out what’s causing the problem?

  97. What a great tool! The user interface is especially smooth and intuitive, and the hover text that decodes each element of the regexp is really useful. It’s a delight to use.

  98. I noticed that e.g. [a-z]+ highlights all matches as expected, but [a-z]* doesn’t but it still replaces as expected.

  99. This is an awesome tool I stumbled across after a Google search. Helped me alot with a project I’m working on. I especially like the ‘as-you-type’ feature.

  100. Absolutely fantastic, i want to have your babies.

    Far easier to learn regex with this.

  101. Great tool. Was useful today when I found out that my text editor didn’t support greedy/lazy quantification.

    Suggestion: Could you highlight the text inserted/deleted by the replace tool? Would make it more intuitive to see what exactly the replace command did.

  102. After updating my AIR runtime the app does not run anymore. It says it´s running on aunsurported air version.

    I´m using the latest air runtime

  103. Excellent tools ! Well done.

    I have a suggestion for a good feature (well this is what I would need in fact 😉 ):

    Propose a different highlight color for each matched group. Indeed if you specify several groups in your expression, all the match is highlighted with only once color, and then you cannot easily see what part of the expression matches each group.

    Thanks again.

  104. Michael Dean May 28, 2010 at 2:41pm

    I don’t have an execute button on my display…I’m not sure how to trigger the evaluation

  105. I love this tool, it make me win many time!

    Just one think and it will be perfect : make the patern field multiple lines when ‘extended’ option is On.

    So instead of :


    We can do :


    (1[-\s.])? # optional ‘1-‘, ‘1.’ or ‘1’

    ( \( )? # optional opening parenthesis

    \d{3} # the area code

    (?(2) \) ) # if there was opening parenthesis, close it

    [-\s.]? # followed by ‘-‘ or ‘.’ or space

    \d{3} # first 3 digits

    [-\s.]? # followed by ‘-‘ or ‘.’ or space

    \d{4} # last 4 digits


    Inspired from here :

    Thanks again

  106. I don’t have an Execute button on the online version. :(

  107. There is no execute button. It executes as you type. You’ll see the match results highlighted in real time in the source text.

  108. Hi Grant, what do you think about my proposition (multiple line patern when ‘x’ option) ?

  109. You guys are absolutely pimp. I was needing to get drop down list values formatted into HTML and you guys saved my ass. This rocks better than any regex editor I’ve seen and its freaking free. You rock hard.

  110. Hi Grant

    That’s a great tool. I am new to RegEx and this is make learning some much easier.

    I was wondering if it is possible to replace specify different replacement of each captured group. For example replace group 1 by “”



  111. its a very useful tool.

    thank you

  112. Excellent! Time and money safer – big time!

    Only one question: Where can we donate?

  113. I think the negative look behind is not working properly. It isn’t doing what I’d expect and when you mouse over it it says negative lookahead.

  114. Thanks for great tool. It’s very usefull for me and fits better than other similar tools.

    I’d like to suggest feature for next releases, if any.

    It will be very nice to have ability to chain test several replace regular expressions in batch. I mean first expression applied to source text, second expression applied to result of first and so on.

    Thanks again.

  115. Thank you for very nice service!

  116. Hi Grant,

    I’m using regex’s like most of programmers now and than. But so far I did it more the try’n error way. Today, finding and using your tool (air app) all of an sudden it went klick in my head. You helped me A LOT man, getting the way regex and most of all replace works, into my head.

    I appreciate your work



  117. Andreas Blinkenberg September 29, 2010 at 7:21am

    Hi, just found this online regexp-tester. It’s great.

    But somehow I don’t understand what your empty lines consist of?

    In your sample text these regex’es doesn’t return any matches:




    If it’s because the engine strips newlines, then why do I get a match with .\r and not with \r

    With multiline selected I cannot find any newlines either:




    and this: ^.*\r$ only matches the 2 lines that have empty lines after them.

    Is it an engine bug, or can you explain this behavior?

  118. Andreas – This is actually a visualization issue. CRs & LFs do not have any boundary areas, so they are not highlighted. Thus, if your match only consists of these characters, you won’t be able to see it.

    For now, you could use a replace to see where the matches are occurring (ex. replace them all with * or something).

    Perhaps I should add a short summary at the bottom indicating the number of matches, and/or figure out a way to visualize matched new line characters.

  119. Andreas Blinkenberg September 29, 2010 at 11:34am

    Thanks for a fast answer.

    And I can only say: but of course.

    I don’t know why it didn’t cross my mind to try and replace them.

    A visualization would definitely be a nice feature, also a feature that few others have implemented.

    Maybe the user could choose to see these via a checkbox.

    Maybe give them a color, so they stand out…

    Other invisible characters could also be of interest, for instance:

    utf-8 decimal 65279 – zero width no-break space

    and maybe utf-8 decimal 1-31 although few of these are ever used.

  120. What a fine project tool, Grant, thank you for sharing this with the community.

    Couple Questions…

    1 ==============

    ?-PORTABILITY (the online tool version): When you save to “My Saved” the entry(s) appear to be saved in the Flash Player Local Storage Cookie, is this correct?

    **I was hoping to be able to access my online saved stuff on my portable USB stick ;^)

    Can you recommend a method/procedure for doing so?

    My concern would be that if I had changes to merge from one “regexr_patterns.sol” file to another (assuming that is the item to save/copy/?), since its binary how could one do that?

    And/or, if I go to another machine where the user already has their own stored there, how could I bring mine up? Esp on a portable stick ;^)

    And/or to merge from+to the Desktop App?

    2 =========

    SAVE EXAMPLE/RESULTS?… any plans to save the “example” section so when you load a saved item you can see the pertinent substitution that apply to that?


    Thanks ;^)

  121. Oh thank you so much, regexp always frustrates me, this tool is invaluable!

  122. The execute button is not showing for me at all.. on the Online version or desktop..

  123. Ricky – the newer versions do not have an execute button. They display results in real time.

  124. First, this is one of the best tools that I use on a regular basis, thanks a ton!

    I ran into an oddity between the desktop version and the web one. Here’s a screenshot of the two. Seems to be just a highlighting issue as replacing works as expected.

    I think it has to do with newline characters since moving everything to one line fixes it. (on Mac)

  125. Online version needs work. The ‘replace’ section doesn’t always get updated. (Using FF 3.6.13)

  126. The great project! Thanks a lot!!
    But I found a bug. Hints are buggy on this regexp: \[([^\]]*)\]
    When I moveover cursor on \] it can’t recognize it, it thinks that pattern [^\]] is not-\ pattern primary. But it’s not-] pattern.

  127. Big thanks for this tool. Except for some moments with text selection and cursor, it’s a great thing, especially text in the beggining of work and community.

  128. Loving the browser app, clean, simple and easy to use. =)
    Grabbing the desktop version for sure next time I’m on my Mac.
    I’m sure it’ll come in very handy in the up-hill struggle that trying to bend my brain around regex is proving to be. =P

    Got a snippet I’ve knocked up which I wildly claim you should include: (providing it doesn’t get shot down for inefficiency by a regex guru in 2 seconds flat ;))


    Matches floating point/decimal numbers, without allowing any trailing or leading 0s other than to express 0.x

    (Tips on improving it, anyone?)

  129. i like regexr but i don’t like adobe air so please create stand-alone desktop version

  130. Very useful tool, thanks a lot. Bookmarked.

  131. Thanks for the work on this tool – it’s very useful and I’ve shared the link with my dev team. Cheers!

  132. Josep M. Fontana March 18, 2011 at 10:59am

    Great app. Very useful for a starting programmer. Thanks! Would you accept a suggestion? There is one thing that would make this better for people like me who have sight problems: being able to increase the size of the characters. If you could implement this, I would be really grateful.

  133. Hi, noticed one thing (dont know, if its a problem or not)

    (match point, brackets, semicolon)
    this regexp –> \|\\]|\\[|\\.|\,

    in regexr its not working, but in as3-code, does
    from the other side
    this regexp –> \|\]|\[|\.|\,

    in regexr is working, but in as3-code, does not

  134. Great tool ! I love it 😉

  135. Awesome, I was trying to do a find and replace in notepad++ using regex and this tool came in handy although for some reason, using regex for the replace function in notepad++ doesn’t seem to work like it does here.

    I’m trying to do a replace on the first character for each line in a single column of text using the RegExp: /^./gm (I’m simply typing “^.” in my search without the quotes).

    Awesome tool and great for someone like me who is new to the power of regex!

  136. Hi Grant-

    Thank you for RegExr; it makes a convoluted task so much simpler.

    I found a rather strange behavior: When an expression has been added to the ‘my saved’ tab and then the menu item is either double-clicked or the ‘load’ link is clicked, it replaces the full expression that is being authored. However, when adding an expression from the ‘samples’ tab it appends it.

    I understand that the first makes some sense, but would prefer that clicking a saved expression appended it.

    Thanks again!

  137. Sandro Berri May 19, 2011 at 3:02am

    I use it often and it’s a fantastic source!
    Thank u

  138. so where is the desktop apps? i cant believe it is made in 2008, and im commenting it now 2011. It was 3 years ago.. hahaha

  139. I love every single aspect of this application except for one…

    There is no Text Extraction tab or something akin to that. Where you could extract and output formatted results of reg expression search. Say if you wanted to extract all emails out of a file or phone numbers or something else. Rather than specifying how to take into account the rest of useless information and dividing everything in capture groups it could list all matches in separate field based on formatting that one could specify.

    I might not be an expert but given that you tackled on-the-fly replace(which i really admire) it probably won’t not be very hard to implement.

    With this it will be the ULTIMATE editing tool.
    Nevertheless Thank you for such a great application!

  140. Simple feature request:

    Would you please number the groups in the regular expression field? This makes it simpler for the user to identify the tool’s group references such as:

    ^group [1234567890]+

  141. Kurt Whittemore July 14, 2011 at 10:22am

    Great tool!!!!
    I think it could be even greater if you supported (?!test) so that one could quickly match everything that is not the group you are searching for. This would allow you to extract all the text you want real quick. Just match everything that is not what you are looking for, and replace that with nothing. Then your left with just the part you were interested in.

  142. This is a fantastic little tool. I use it a lot and it’s taken pretty much everything I’ve thrown at it. This is in fact the only regex tool I’ve come across that will handle PERL Compatible RegEx syntax correctly without having a nervous breakdown.
    I use a lot of PC Regex named groups in the form of (?<name>.*) etc. I then reuse them using \k or (?(name)…). (Yes I’ve even used (?R) for recursion).

    One minor niggle….

    The capturing groups summary unfortunately won’t show these properly at the bottom because they look like html tags in the browser version of RegExr. Also beyond a certain length the nesting highlight stops working on the regex string as well.

    I’ll try and put in the horribly complex 500 char regex I’ve been debugging with the help of your beautiful tool but I don’t think this little wordpress post form would like the use of the <> chars in it and probably filter them.


    Can you guess what it is yet?

  143. Sorry I’ll try that again…


  144. I’m attempting to use a back reference within my regex, which should be valid. However it doesn’t appear to be working with Regexr. I’m not sure if it’s a bug within my regex or within regexr but I wanted to let you know about it so that you can test.

    Full reference, matching works:

    Using back references within regex, matching does not work:

    Thanks for the excellent app. I use it all the time.

  145. andy – yes, it looks like a problem with your pattern. It appears that you expect the backreference to reference the pattern, but it actually references the match.

    So, for example, with the string “AA”, the pattern (\w)\1 would match, because the first match “A” would be backreferenced and match the second “A”.

    However, the string “AB” would not be matched, because the backreferenced match “A” does not match the next character “B”.

    I hope that makes sense.

  146. Ahhh. yes that does make sense. Not what I was expecting, but it’s logical.

    Thanks for responding Grant.

  147. I was looking for a way to grep out all the files from a list of files and directories obtained from a “find .” (ie. looking for lines with a file extension ).


    I’m not sure if you’re trying to match bash exactly but as I was experimenting, there were some differences.

    “.+\..+” worked in regexr, but returned nothing in grep
    “[^\.][\.]” worked in grep, but highlighted the directories as well in regexpr

  148. Excellent tool. Thanks for sharing !

  149. RegExr is a great tool, and I’m very grateful for the fact that you provide it for free!

    I think I’ve spotted a couple of little bugs in tooltip display:

    1. Description of “+?” in the toolkit sidebar says: “Matches 0 or more of the preceeding token.”, and it should be “Matches 1 or more…”

    2. Tooltip description of “(?<!t_)" in the main regex text field is "Negative lookahead matching 't_'.", I think it should be "Negative lookbehind matching…"

    Very minor things in an otherwise fantastic tool!

  150. I can’t tell you how helpful this tool is; thank you so much for your work on it!

  151. Why don’t you add some unicode support?

  152. Can you please add ability to copy the end-result/selection of the RegEx? That would be indispensable. Thanks.

  153. If you could switch the font to a fixed-width font, that would make this tool even better. Fixed-width fonts make zeros and Os stand out more, among other things.

  154. I use your regex tool everyday.

  155. excellent job. loving the air app too. thanks

  156. thank you so much for this wonderful tool!!

  157. Don’t use regexes much, but when I do, I always use your tool to help myself out. Thanks.

  158. Would it be possible to have one colour highlight by grouping?

  159. Very useful tool! You are a genius!
    Can you also add monospace font for main text area? For example Courier New.
    Better add possibility to user can select between monospace and non_monospace fonts.
    Thanks a lot!

  160. Excellent the work you’ve done on RegExr. I’ve used RegExBuddy for many years on the Windows world, and ever since I plunged into the Linux world I had missed something similar.

    I’ve just discovered it and just used it once, but I’m impressed by your tool, and I’m sure it’ll become my favourite tool for regular expressions.

    Great job!!

  161. Hi, man,happy new year! You have done a great job for us and your tool makes our daily job so easy, thank you very much!

  162. Can You add utf-8 support? (flag /U)

  163. Hi Guy !
    Thanks for this application. It very useful for the team and I.
    Good Job !!

  164. Great tool ! Very helpful and simple. Dealing with regex’s was never so easy. I end up using RegExr whenever I am having to deal with regex.

    Thanks for your efforts !

  165. I LOVE this, thank you SO MUCH! 😀

  166. Great app, it’s my go to regex tool. It would be super useful if the text fields supported undo typing and tab character input (Air bug?). Anyway, great app!

  167. Great app thank you so much I can’t tell you how grateful I am

  168. Great to test regular expressions. Having an option to collect matches in an other textfield (using groups) would make it extremely useful.

  169. I love this tool so much! Thank you for providing it so generously free of charge, I really appreciate it.

    Now that I’ve buttered you up? If you get the time, I just wish there were a way to extract the “My Saved” regexes. Is there anyway you could possibly allow for a quick export? csv, xml, text file, smoke signals, anything, please? :)

    Thanks again so much!

  170. Excellent utility. If the customization of font family and size is possible (not knowing the limits of Adobe Air), RegExr would be perfect.

  171. Shardul Jain May 8, 2012 at 2:50pm

    I believe negative lookbehind is broken in your code.

  172. Great little utility. Wish it had cut-paste & undo-redo support. Is this project still actively being developed? If not, ever think about making it open source?

  173. This tool is EXCELLENT and very useful for any web developer! Thank you very very much, you’re so great!!!
    Luca from Italy

  174. I’ve run into a problem using your online app RegExr. I used it to develop a bunch of expressions, but not we are attempting to use the expressions in a C# program and they will not execute. I’m not a RegEx expert, but what are we doing wrong?

  175. Any chance to file a bug report?

    When doing a replacement and the replacement string is empty (i.e. find something and replace it with an empty string), the generated short URL does not point to the replacement page with the filled empty string but to the match page.

  176. Very Useful tool

  177. Thank you for this useful tool!
    I have some cosmetic proposals:

    1) Comments.
    The line above shows a comment. The Expression is executed the right way, but the comment is shown as capturing group
    2 capturing groups:
    group 1: (\w*(?#KernelName))
    group 2: (?#KernelName)

    2) Escaped brackets
    The line above shows a match until the next closing bracket “)”
    This is not shown correctly as capturing group:
    2 capturing groups:
    group 1: ([^\)
    group 2: (?#KernelParameters)

    3) Matches
    Is it possible to add a new text-box showing all matches as a list for easier copying of the results?
    Something like:
    group 1: “match 1”, “match 2”, “match 3”

  178. It would be awesome if you put the source code online so we could help you update it.

    Great app, thanks!

  179. usually the groups are referenced with slash \ char, not dollar one $

    why do you use $ instead?


  180. This is great!

    It would be nice if you would say what kind of regex you are doing – I would assume PCRE. It would be cool if you could switch to various types of regex: perl compatible, php (with named subpatterns), grep, bash single/double quoted.

    It would also be nice if there was an option to switch the separator to a different character – I often use @ or # instead of / if I’m working with strings with a lot of slashes.

  181. In the examples I suggest to change the “Simplified example of matching HTML tags” to “]+>”

  182. the code got cut off.. :(


  183. Hi there,

    I’m beginner in regex and I’ve found this tool indispensable and easy to use. Two questions:

    1. What does it mean when my regular expression has a font color of red? For example, .* is displayed in red color.

    2. Specific question:
    Regular expression: 9*
    Text input:
    I noticed it only matched the first line, 99, but no subsequent lines. Is there a reason why it’s not picking up the following lines? I tried different options (dotall, multiline) and got the same result. Regexpal picked up the following lines though.


  184. David – red text means that it is an infinite match. For example:

    This can match 0 characters, which means it will always find a match. That’s also why 9* is only finding the first line. It matches the first two 9’s, then matches the following “zero 9s” infinitely. Try using “9+” (one or more 9s) instead.

  185. Grant, I just found this tool, after nearly 30 years of looking for it! How did you know? :)

    Seriously, I haven’t stopped grinning since I installed the desktop version. I love the fact that you’ve included community examples, they are a fascinating resource – watching how other folks have approached the same problem from a different perspective in some cases.

    What a great way to hone my regexp skills. I’ve already wasted hours expanded my understanding, with plenty more to go. Thanks a squillion.

    May the Bluebird of Happiness never shit on your shirt.

    Cheers from ɹǝpun uʍop!
    PC Pete

  186. Great tool! Lots of good stuff there. Thanks!

    Just wondering if your RegExr tool can be configured to have support for different flavours of regular expressions, eg, Python, Perl, JavaScript, VBScript, XQuery, XPath, Oracle, POSIX Basic Regular Expressions, POSIX Extended Regular Expressions.

  187. What’s going on with window newlines? Is there any way you could add a setting to make windows newlines only count as 1 newline in the RegExr? Everytime I copy/paste to/from this, it freaks out.

    I imagine this is using unix newlines and windows uses \n\r

  188. Really great tool!
    Is it possible that regexr could be translated into javascript now that Adobe have discontinued development of AIR in Linux?

  189. In Google Chrome, when pasting multiple lines of text from a <textarea>, every new line gets 2 linebreaks instead of one. So, copying


    into regexr, turns into


    Please fix this. Regexr is my go-to place for regex replacing, and because of this bug I can’t use it for that anymore.

  190. So…..the execute button is missing,checked Chrome, IE and Firefox…what am I missing here?

  191. Grant – there is no execute button. Results update in real-time as you type.

  192. Such a great tool for learning and mastering regular expressions. Thank you so much for the website version and especially for the desktop version.

  193. Thank You!

    This tool is just what I was missing.

    Best regards,
    Lars Hansen – Hillerød – Denmark

  194. Hello Mr. GSkinner.

    First thank you for your fantasic Regular Expression Online tool. It’s the best one I have seen online.
    I have a question about this one. Does there exist an option to show the filtered code of a regular expression to copy&paste it ?
    It would be nice to do so. So there would be no need for another one anymore to save the results. :/

    Maybe an addition checkbox or window popup to show filtered results..

  195. Great tool. I’ve recommended this tool to many of my co-workers.


  196. A superb tool!! When I used Windows I used to work with RegBuddy. Now that I use linux I use your tool and I don’t miss Regbuddy.

    Great!! Thanks a lot for such a good job!


  197. Thanks for the nice tool.

    Just a tiny typo in the help text for the

    qualifier +?
    “Matches 0 or more of the preceeding token. […]” should read
    “Matches 1 or more of the preceeding token. […]”

  198. Your utility is outstanding! Thank you for this extremely helpful contribution to the world of IT.

  199. The best tool I’ve ever seen. Thanks…

  200. I thought Expresso was good, but this app is a blessing! Thank you so much!

  201. Awesome !! i like this app…good job !!

  202. Just want to say thanks. This saved my day!

  203. Very useful too. Thank you for making this available to us at no charge.

    One suggestion. I find it very difficult to see what is being highlighted in the text in the whiteboard space. For example if I’m highlighting a word and the space following it I can’t easily see if the space got captured. I tried increasing the Zoom and Text Size without any success. (I’m using IE8.)

    If you would find a way to allow the user to pick a font size for different sections (or at a minimum the whiteboard) that would be terrific. Being able to pick a highlight color might be useful to some. (I tried, unsuccessfully, to include a screen shot.)


  204. I am using a regex in Oracle as follows:


    When I try to validade any string at it, it gives me the error “invalid range in regular expression”. When I put a “\” character after the “\\x00” like:


    the error disappears. Did it really solve the problem? Is this new regex the same as the other one? Thanks!

  205. Thanks you very much for this useful tool !!! It work perfectly !

  206. I’ve been a developer for more years than I care to remember, and always managed to avoid regex. There are so many resources out there which just seem to make it more difficult, but 5 minutes using RegExr and I get stuff that I never did before!

    Awesome, dude. Just awesome. I thank you from the bottom of my geeky heart 😉

  207. Very useful, but would be much nicer IMO if you showed what was contained within each captured group instead of just saying that something was captured. Cheers!

  208. Regarding last comment: I just noticed that the groups DO show in the pop-up bubble, but it might be nice for them to show in the lower window (so guys like me can’t miss it).

  209. I have been using your desktop version for a few years now and I love it. What do you think about porting it to Android? I do some development on my tablet, and having a tool as awesome as yours would be great! I’ve tried others, but I’m spoiled by yours.

  210. Could you please add to “capturing groups” part values if these groups ?
    it would be very useful.

  211. Good tool, but looks bad on 23″ (1920×1080) – All elements and texts, too small )

  212. Very nice. I’ve used a lot of RegEx tools in the past, but believe that this is best. I’ll try the desktop version next.

  213. calculatorstore July 29, 2013 at 1:28pm

    Great site. I noticed an issue with the positive look back, it looks like it is unable to handle quantifiers.
    Example (Replace):

    Pattern: (?<=\w+)\w
    Replace: *
    Target: John Smith
    Expected: J*** S****
    Actual: John Smith


  214. Great tool. Thank you.

    Could you please make the fonts bigger or adjustable?
    On my huge screen I can’t see your tiny letters anymore… .-)

  215. My most sincere gratitude for this wonderful tool.

  216. Thanks for the tool.

    Could you please make it save the replace and flags (ignore case, multiline etc) beside the regexp. Currently it just save regexp.

  217. I’ve found this tool useful for years. Thanks for keeping it going for so long.

  218. Amazing tool, many thanks for it!

  219. Love it… very useful.

  220. “bdxxxx” won’t be recognized by the regex “([abc]*)|bdx+”!

  221. anonymous – this is correct. Notice that the pattern is red in RegExr which indicates an infinite match. This is because the first option in your pattern can match 0 characters, so it will continue matching 0 characters infinitely.

    try something like this instead:

  222. This is really great – helpful for us slowly struggling to learn – I like example, references, tools – and cool work. It is cool :) Thanks

  223. can anybody tell me how can i use this tool, for everybody’s info i am willing to use it generate/test regular expressions i will use in jMeter.

  224. Not just useful for learning, it’s also great for testing patterns before implementing them. Saves me a lot of var_dump’s. Thanks

  225. TWO WORDS “Awesome App” Thanks

  226. Greg….Will you marry me?


    Joanne Norvell

  227. anyone else having problems with the RegEx tool not working?

    after an update to Firefox, or more likely Flash 11.9, the tool no longer works – it loads with all fields blank and any epression entered has no effect

  228. I’ve been trying a few similar tools but this is my favourite. Great job. Agree larger font sizes would be good – also nice if you could edit your saved expressions instead of just adding or removing.

  229. Awesome tool.

    Could you possibly change the font to monospace?

  230. I also agree about the larger fonts!
    This is a very nice tool, and would more than perfect for us here if fonts were adjustable!

    Thank you fopr this very nice tool.


  231. There is an error in explanation: The first member of
    you explain as Lookahead, while it's Lookbehind

    And I also agree about the larger fonts!

  232. very nice ,thank you ~~!

  233. does not appear to work in Firefox 27.0.1 or IE11. Works fine in Chrome.

  234. Hi, im student and i need information about this app, like specifications and the way the program valid the regex

  235. Regexr is a very useful tool, even if you’re familiar with regular expressions. Thumbs up!

    But something is broken with your V2. Can’t use it with up-to-date FF29 beta. See here:

  236. Does this have named capture support while capturing groups? Somethings like I can do in C# – (?[a-z]) will return all lower case letters in a group named AllLowerCaseLetters. Am I missing something? Excellent tool, by the way! Thanks!

  237. Nicolas Combecave July 14, 2014 at 2:41am

    Congrats for the new version, it’s much more convenient, and very nice to use!!!!
    Thanks for your efforts!


  238. Very useful tool, I like your version 1.0 instead of new version of regexr. If you are planning to remove version 1.0 then please don’t :)

Comments are closed.