2


did anybody know a good regex tester for javascript (i think there are differents between php regex and javascript? right?)

Thanks in advance!
Peter

1
  • 1
    Have you seen www.debuggex.com? It's very visual and gives you real-time feedback for quickly understanding a regex. Commented Apr 9, 2013 at 21:58

8 Answers 8

5

From my answer to this question:

I think you will find www.debuggex.com very valuable. Some advantages of debuggex are:

  • Feedback is in real-time, so you can understand what's happening faster
  • The ability to answer the question "Why does/doesn't it match here?" for any position in your text.
  • Very heavy on the visuals, it was a core design decision behind it's creation

picture of Debuggex

At the time of writing, it only supports Javascript. However, more languages are planned for the future.

Sign up to request clarification or add additional context in comments.

2 Comments

Excellent tool. Wish I could upvote more. A bit of a learning curve but the video helps a lot.
I wish I could paste text into debuggex, I would like to use it :/
3

A very good (though not free) regex tester, debugger and converter is RegexBuddy. It's especially handy if you need to convert regular expressions from one flavor to another, and there is a grep tool built in.

RegexBuddy screenshot

Comments

2

Rubular

It's actually for Ruby but it's pretty good for testing most standard regex. It allows lookbehind though which Javascript does not implement.

1 Comment

Apologies, it doesn't allow lookbehind!
2

Try Rejex, it's a regexp tester for javascript

Comments

2

For online testing try this realtime tester http://regextester.net/live-javascript-regex-tester.php

Comments

1

There are differences, yes. There can even be slight differences in how regex is implemented between browsers (e.g. IE's "JScript" variant vs. Firefox), surprise surprise.

You should find plenty of JS-oriented regex testing tools on the web though. For example, I've used this one in the past, which is written in Javascript:

http://www.regular-expressions.info/javascriptexample.html

Comments

0

You could try http://regexpal.com/

Comments

0

You could try http://webdevweapons.com/regextester/ It is simple and easy to use with the regex docs along side it for quick reference.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.