pythex
A Python re module tester that runs entirely in your browser.
>>>
>>>
Match result:
Match captures:
Results will appear here.
Pattern debug:
A Python re module tester that runs entirely in your browser.
Loading Python Environment...
This might take a moment.
A Python re module tester that runs entirely in your browser.
>>>
>>>
Results will appear here.
\ | escape special characters |
. | matches any character (newlines only if DOTALL) |
^ | matches beginning of string |
$ | matches end of string |
[5b-d] | matches '5', 'b', 'c' or 'd' |
[^a-c6] | matches any char except 'a', 'b', 'c' or '6' |
R|S | matches regex R or S |
() | creates a capture group |
* | 0 or more |
+ | 1 or more |
? | 0 or 1 |
{m} | exactly m occurrences |
{m,n} | from m to n |
{m,n}? | from m to n, as few as possible |
*? | non-greedy |
\A | start of string |
\b | word boundary |
\B | not word boundary |
\d | digit |
\D | non-digit |
\s | whitespace |
\S | non-whitespace |
\w | alphanumeric |
\W | non-alphanumeric |
\Z | end of string |
(?i)(?m)(?s)(?x) | sets re.X flags |
(?:...) | non-capturing group |
(?P<n>...) | named group |
(?#...) | a comment |
(?=...) | lookahead assertion |
(?!...) | negative lookahead |
(?<=...) | lookbehind assertion |
(?<!...) | negative lookbehind |
(?(id)y|n) | conditional match |