Free browser-based tool

Regex Line Filter

Filter pasted lines with plain text or safe regular expressions, preserve original line numbers, and keep, remove, or extract matching content.

Plain text or regex
Guide

Keep, remove, or extract matching text with safe regular expressions

Line filtering is useful for logs, identifiers, URLs, exports, and validation lists. Multiple rules can match with OR or AND behavior.

Regular expressions are compiled directly by the browser and applied to each line. Invalid patterns produce visible errors and are never executed as code.

Common questions

Regex Line Filter FAQ

What is the difference between keep and remove?

Keep returns lines that satisfy the rules. Remove returns lines that do not satisfy them.

What does extract mode return?

It returns the matching portions of each line rather than the complete source line.

Can multiple regular expressions be combined?

Yes. Enter one rule per line and choose whether any rule or every rule must match.

Related tools

Continue working with your data

All tools