Master regex patterns for pattern matching and text manipulation.
Join the AI Workshop to learn more about AI and how it can be applied to web development. Next cohort February 1st, 2026
The AI-first Web Development BOOTCAMP cohort starts February 24th, 2026. 10 weeks of intensive training and hands-on projects.
Regular expressions (regex) are powerful patterns used to match, search, and manipulate text. JavaScript provides built-in support for regex through the RegExp object and string methods.
In this unit, you’ll learn how to:
- Create and use regular expressions
- Match patterns in strings
- Use anchors, quantifiers, and character classes
- Work with groups and capturing
- Handle Unicode and special characters
- Apply regex in real-world scenarios
Lessons in this unit:
| 0: | ▶︎ Introduction |
| 1: | Introduction |
| 2: | Anchoring |
| 3: | Match Items in Ranges |
| 4: | Matching a Range Item Multiple Times |
| 5: | Negating a Pattern |
| 6: | Meta Characters |
| 7: | Regular Expressions Choices |
| 8: | Quantifiers |
| 9: | Optional Items |
| 10: | Groups |
| 11: | Capturing Groups |
| 12: | Using match and exec Without Groups |
| 13: | Noncapturing Groups |
| 14: | Flags |
| 15: | Inspecting a Regex |
| 16: | Escaping |
| 17: | String Boundaries |
| 18: | Replacing |
| 19: | Greediness |
| 20: | Lookaheads |
| 21: | Lookbehinds |
| 22: | Unicode |
| 23: | Unicode Property Escapes |
| 24: | Examples |