g · global Find every match, not just the first. Without it, replace changes only the first match. regex.global i · ignore case Letters match in either case: a matches A. regex.ignoreCase m · multiline ^ and $ match at the start and end of every line, not only of the whole text. regex.multiline s · dotAll . matches line breaks too, so it really is any character. regex.dotAll u · unicode Read the pattern as code points rather than UTF-16 units, and allow \p{…} and \u{…}. Stricter about escapes. Turns v off. regex.unicode v · unicodeSets Everything u does, plus nested classes, && and -- inside [ ], and \q{…} for strings. Turns u off. regex.unicodeSets y · sticky Match only exactly where the previous match ended (lastIndex), never further along. regex.sticky