Contents in capture group `foo`
\{foo}This will return a string with the contents from the capture group named `foo`. Any name can be used as long as it is defined in the regex. This syntax is made up and specific to only Regex101. If the J-flag is specified, content will be taken from the first capture group with the same name.
Examples
PCRE PYTHON
Share & Embed
Use this snippet to display this token on your own site.
<!-- Embed Regex Token: \{foo} -->
<code class="regex-token">\{foo}</code> - Contents in capture group `foo`
<small><a href="https://testregex.com/cheatsheet/contents-in-capture-group-foo-slash-brace-openfoobrace-close">See details</a></small>