PicoToolkit
Extracted data:
0 characters
0 without spaces
0 words
0 lines
IndexValue
No matching items found
Spotted a bug or have an idea for a new feature? Let us know here »

Filter a list

The quickest method of list filtering

This tool scans a multiline list line-by-line and keeps or removes lines that match a pattern. Use plain text for simple substring matches or enable the RegEx checkbox to apply regular expressions for powerful, flexible filtering.

How to use

  • Paste your list into the input area.
  • Enter a pattern (plain text or regex).
  • If needed, check the RegEx box to treat the pattern as a regular expression.
  • Choose the filter mode: Leave matches (keep matching lines) or Remove matches (discard matching lines).
  • Click Filter and copy the result.

Example usage

Extract ASUS models from a product list:

  1. Pattern: ASUS (leave RegEx unchecked for a simple substring match).
  2. Set filter type to Leave matches.
  3. Click Filter.

Result: only lines that contain "ASUS" remain.

How the tool processes input

  • Each input line is tested independently against the pattern.
  • With RegEx enabled, the pattern is treated as a regular expression; without it, the tool performs a plain substring match.
  • Use anchors (e.g., ^, $) and boundaries (e.g., \b) in regex mode to refine matches.
  • For best results on lists, pre-clean the input (remove empty lines, de-duplicate) before filtering.

Examples & copyable regex patterns

  • ^ASUS — lines starting with "ASUS".
  • \b\d{4}\b — lines containing a 4-digit year (e.g., 2022).
  • ^(?!.*refurb).* — exclude lines that contain "refurb" (negative lookahead).
  • ^[^@]+@example\.com$ — match email addresses from example.com.
  • ASUS (RegEx off) — simple substring match for "ASUS".

Tool chaining (workflows)

Tips & edge cases

  • Test your regex on a small sample before running it on a very large list.
  • If results are unexpected, try escaping special characters or toggling the RegEx checkbox to compare behavior.
  • Use anchors (^, $) to avoid partial matches when you need exact-line matches.
  • For bulk lists, consider de-duplicating (Remove Duplicates) after filtering.
  • If you only need to remove lines containing a simple substring, consider Remove Lines Containing String for a quicker workflow.

FAQ

Does regex mode support case-insensitive searches?

The tool is case sensitive. If you need to make in non case sensitive - normalize case in a pre-step (convert the list to lowercase before filtering).

What regular-expression features can I use?

The RegEx checkbox lets you use standard regex constructs (anchors, character classes, quantifiers, groups, lookarounds). If a specific advanced feature is unsupported, test the pattern in the tool and adjust accordingly.

How are lines processed — can patterns match across lines?

Each line is evaluated independently. Patterns should be written to match a single line; multiline matches across line breaks are not applied unless the engine supports special flags — test your pattern on representative input.

Can I filter many strings at once?

Yes — paste a multiline list and run the filter. For best performance, remove empty lines (Remove Empty Lines) and duplicates (Remove Duplicates) beforehand when working with very large datasets.

What should I do if my pattern doesn't return expected results?

Verify whether RegEx is enabled, test a simpler pattern, escape special characters, and try anchors or word boundaries. Use small samples to iterate quickly before filtering the full list.

Related tools

PicoToolkit evolves fast. Stay ahead.

Get early access to new tools, features, and productivity upgrades.

Unsubscribe anytime.
© PicoToolkit 2022-2026 All rights reserved. Before using this website read and accept terms of use and privacy policy. Icons by Icons8