Skip to main content
The RegExp validator checks a value against a regular expression without changing it. Use it for values that have to follow a known shape — reference numbers, postal codes, internal identifiers.

Options

The pattern has to match, not match the whole value, so anchor it with ^ and $ when the whole value must conform. ^\d{4}$ accepts only a four-digit value, while \d{4} accepts anything containing four digits in a row.

Examples

How it behaves

This is the validator, which checks values and leaves them alone. To rewrite a value with a regular expression, use the RegExp formatter instead.