Regular Expressions
This guide and quick-start index is targeted at anyone who wishes to learn more about regular expressions. Code examples are written in the Java language, for clarity, but concepts and explanations are pure regular expressions.
If there is a tip or trick that you would like to contribute, or if you have a question that is not answered here, please feel free to submit a tip, or leave a comment with your question. To receive periodic email updates when new articles and tutorials are posted, please [[Subscribe|subscribe to our newsletter]].
Java visual regex tester
Try our visual java regex tester.“Or” in regular expressions `||`
A quick guide using several examples to create and use logical “or” statements in regular expressions.
Email Addresses with Regular Expressions
A quick guide demonstrating how to validate email addresses with regular expressions and other native languages.
“And” in regular expressions `&&`
A quick guide using several examples to create and use logical “and” statements in regular expressions.
Password Regular Expression
A quick guide on writing password constraints using look-aheads, alternation, non-capturing groups, and more.
Guide to Regular Expressions in Java (Part 1)
A detailed guide using step-by-step examples and tutorials to explain not only basic fundamentals of regular expressions, but also how to apply them to more complex scenarios using the Java language. Explains character classes, quantifiers, grouping and alternation, and more.
Guide to Regular Expressions in Java (Part 2)
A detailed guide using step-by-step examples and tutorials to explain advanced fundamentals of regular expressions using the Java language. Includes Look-aheads, look-behinds, and how to configure the pattern matching system for multi-line strings, dot-all mode, and more.