Unframed version suitable for printing

Javascript Regular Expression Tester

This page is an online tester with full syntactical support for JavaScript (JS) Regular Expressions (REs) and Replacement Expressions.  It can be used to test REs too difficult, inconvenient, or inefficient to test within code under development.

All of the RE and String methods/functions which use REs can be tested  the input for specifying a replacement expression is only displayed when the appropriate method is selected.

You can specify the RE with or without bounding slashes (/), but when they're included, the checkboxes defining switches are ignored; any required switches must be included in the RE text.

Copy Output To Input can be used when testing a conversion process with several steps.


  1. You will need to double up backslashes (\) when pasting as string literals REs tested here into JS source code;
  2. JS handling of REs varies from interpreter to interpreter, and therefore browser to browser  for example:









Useful links (no endorsement of external sites intended nor responsibility taken for their content):

Updated Description
13/06/2010 v1.1  -  Safer Array for() loops if the Array.prototype is altered.
09/12/2009 Created v1.