Formatting
The tester compiles your pattern and shows every match as JSON: the text, the index in the original string, the numbered groups, and any named groups. Pattern \w+ with flags gu against Odd socks in the dryer. finds Odd at 0, socks at 4, in at 10, the at 13 and dryer at 17. The period is not a match, because \w does not include it. That index list is how you see the spaces the pattern skipped.
Action has two modes. Match is the report. Replace applies the replacement and returns the whole string, not the JSON. Pattern ([bc])at with replacement $1ird on cat bat hat returns cird bird hat. The c and the b were captured. hat does not match, so it stays. Named groups show up on match as the named object; a test of a(?<last>.) against ab ac puts c in the second match’s name last.
Flags are whatever you type. An illegal flag set fails. The library page is a different tool: it offers ready-made patterns for emails, URLs, hashtags, mentions, numbers and phones, and it does not take a free-form pattern. The extractor prints one group as lines. This page is the one that shows where each hit sat.
Text Odd socks in the dryer. Pattern \w+. Flags gu. Action match.
Odd at index 0, socks at 4, in at 10, the at 13, dryer at 17. Groups are empty.
The index is the part a yes/no matcher throws away. socks starts at 4, after Odd and a space, and the period never matches \w.
\w is letters, digits and underscore. The period in dryer. is punctuation, so the match stops at dryer, index 17.
$1 is the first capture. ([bc])at replaced with $1ird turns cat into cird and bat into bird. hat has no match, so it is unchanged.
On each match, the named object holds them. a(?<last>.) against ab ac puts the second character of each pair under the name last.
The library picks a built-in pattern such as emails and runs that. This page uses the pattern you type, and it can replace.