Trusted by 340+ developers

Regex Generator

Generate Regex from plain English for free. Uses ChatGPT API. Enter a description of the Regex pattern you want to generate and click on the Generate Regex button. You will get back the expression, test cases and code snippets for the language of your choice.

Generate a regex pattern to match...

Regex Pattern for words that start with hello and end with d


Find it useful? Share with your friends →

Recently generated

What is Regex?

Regex (short for Regular Expression) is a syntax for matching patterns in text. It's the most common way to search for something in a file or string, and it can be used in many different ways.

For example, if you have a list of email addresses like below:


and you only want the ones that end with, you could use this regex: .*$ to filter them out. This is how it breaks down:

  1. . at the starts means match any character
  2. means the next characters should be
  3. $ means it should be the ending sequence

This was an easy one. Regex can be used to define ANY kind of a pattern:

  1. words that start with a letter
  2. words that have repeated sequence three times
  3. a 10 digit phone number with hyphens in the middle

Using the Regex generator

Regex generator is an online tool that uses AI to generate a regex string from an english description. Just describe what kind of strings you are trying to match and hit go! We also generate 10 test cases, 5 that should pass for the expression and 5 that shouldn't. This way you can quickly determine if the expression is as robust as you would for your use case. We also generate code snippets for your favorite programming languages - JS and Python that can be used right away.