CSS Gradient Generator
Easily create CSS gradients using this online generator. You'll be able to create either linear or radial gradients.
Regular expressions (often shortened to regex or regexp) are a powerful and flexible way to search, match, extract, and manipulate text. By defining a specific pattern made up of ASCII or Unicode characters, you can quickly identify one or more matches within large blocks of text that would otherwise be difficult to process manually.
Regex is widely used across many applications, including input validation, string parsing and replacement, data transformation, log analysis, and web scraping. Whether you are checking if an email address is valid, extracting values from structured text, or reformatting content, regular expressions provide an efficient and precise solution.
With this tool, you can enter a regular expression and test it instantly against your own sample text to see exactly how it behaves. Matches are highlighted in real time, allowing you to fine-tune your pattern and understand the results more clearly. If you’re new to regex or just need a quick reference, you can also scroll down to try one of the built-in examples and see how common patterns work in practice.
This regex tester is ideal for developers, students, and anyone working with text who wants a fast, visual, and interactive way to experiment with regular expressions and improve accuracy.
Enter a regular expression above.
Everything is worked out in your browser and nothing is uploaded. This tool uses the JavaScript regular expression syntax.
Try some of the examples below to get a feel for how this RegEx Tester works. Click Try and the expression and a piece of sample text are put in the fields above. Play around with the regular expressions and you will soon see what is happening.
Learn more about regex with the cheat sheet below, which explains the characters used in regular expressions. It follows the JavaScript syntax used by this tool.
^$.\\. matches a real dot, or starts a character class such as \d.A|BA or B. If A matches, B is not tried.+*?+, *, ? or {m,n} it makes the match lazy, so it takes as few as possible.{m}m times.{m,n}m to n times. {m,} means m or more.{m,n}?{m,n}: it matches as few times as it can.\wa-z, A-Z, 0-9, _).\W\w does not.\d0-9).\D\s\t, \n and \r.\S\b\w and a \W (or the start or end of the text).\B\n \t \r\uXXXX\u00e9. With the Unicode flag, \u{1F600} also works.\p{L}\p{Lu} (capital letter), \p{N} (number) and \P{L} (not a letter).[ ][abc]a, b or c (not abc).[a-z]a to z.[a\-z]a, - or z.[a-]a or -.[-a]a or -.[a-z0-9]a to z and 0 to 9.[(+*)](, +, * or ). Most special characters lose their meaning inside a set.[^ab5]a, b or 5.( )$1, $2 and so on, counted by the opening bracket.(?:A)A without capturing it.(?<name>A)A and also captures it under the name, which you can use in the replace field as $<name>.\1\2, \3 and so on work the same way.\k<name>A(?=B)A only if B comes straight after.A(?!B)A only if B does not come straight after.(?<=B)AA only if B comes straight before.(?<!B)AA only if B does not come straight before.$1, $2 …$<name>$&$`$'$$The online regex tester is a handy tool to help you learn and check regex codes before using them in your projects.
The expression runs with the JavaScript regex engine. Other languages, such as PHP or Python, can differ a little, for example in named groups and in the flags.
Some patterns, such as (a+)+b, can take a very long time on certain text. The tester stops after 2 seconds instead of freezing the page.
Patterns such as a* can match nothing at all. These are shown as empty matches and are not highlighted.
The one built into your browser, which is the JavaScript flavour. Most of the common syntax is the same as in PHP, Python and other languages, but some features differ, so check the details when you move an expression to another language.
Global finds every match instead of only the first. Ignore case treats capital and small letters alike. Multiline makes ^ and $ match at each line. Dot all lets the dot match a new line. Unicode turns on full Unicode support, including \p{L} classes.
Put brackets around the part you want to reuse, then write $1, $2 and so on in the replace field. Named groups written as (?<name>…) are used as $<name>. Use $& for the whole match and $$ for a dollar sign.
Some patterns try a huge number of ways to match and take very long on certain text. After 2 seconds the tester gives up so your browser keeps working. Making the pattern more specific, or avoiding repeats inside repeats, usually fixes it.
No. The matching is done in your browser and nothing is sent anywhere.
Easily create CSS gradients using this online generator. You'll be able to create either linear or radial gradients.
Easily generate CSS grid layout. This grid generator will include footer, header and columns.
This generator will create a fluid or fixed width column layout, with up to 3 columns + header, footer and menu.
Create a CSS menu with this simple to use menu generator.