Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
/
(\{(?:(?1)|[^{}]*+)++\})|[^{}\s]++
/
g
Input 1
1
New
junk text "atomic junk" some junk text followed by a start bracket { here is the actual payload more payload "atomic payload" nested start bracket { - all of this line is untouchable payload too here is more payload "yet more atomic payload; this one's got a smiley ;-)" end of nested bracket pair } - all of this line is untouchable payload too this is payload too } trailing junk intermittent junk { payload that goes in second output file } end junk