Skip to main content
Z

Filter Lines — Online Grep to Keep or Remove Matching Lines

Keep or remove lines matching a substring or regex pattern. Invert match, case-insensitive, trim before match.

Miễn phí Không cần đăng ký Chạy trên trình duyệt Tôn trọng riêng tư Updated

Cách dùng

  1. 1 Paste lines on the left and a pattern below.
  2. 2 Toggle Keep matching (default) or Remove matching.
  3. 3 Switch on Regex for full regular expression power, with i / m / u / s flag toggles.
  4. 4 Copy the filtered result.

Vì sao dùng công cụ này

  • Plain substring match by default — no regex special-character traps.
  • Regex mode with the four most-used JS flags exposed as checkboxes.
  • Invert match flips just the match, leaving Keep/Remove logic intact.
  • Bad regex shows inline, never crashes the page.

Câu hỏi thường gặp

What is the difference between Invert match and switching Keep/Remove?

They are equivalent — "Remove matching X" is the same as "Keep + Invert match on X". The two controls just make common phrasings ("keep lines that do NOT contain", "remove lines that do NOT contain") quick to express.

What do the regex flags do?

i = case-insensitive, m = multiline (^ and $ match each line), u = full Unicode, s = dot matches newline. We always run per-line so m has limited effect here; useful when your pattern itself spans newline-escaped sequences.

How does Trim before match interact?

The line is trimmed only for the match decision; output lines keep their original leading/trailing whitespace.

Related tools?

Use Deduplicate Lines to drop duplicates, or Sort Lines to reorder after filtering.

Filter Lines là gì?

A Filter Lines tool is a tool that keeps or removes lines of text matching a substring or regular expression pattern. It supports inverting the match, case-insensitive comparison, and trimming each line before matching. Running entirely in the browser, it works like an online grep for filtering text, letting users find and remove lines containing specific content without sending data to a server.

Tóm tắt

Filter Lines là công cụ sáng tạo miễn phí của Zerethon Tools. Keep or remove lines matching a substring or regex pattern. Invert match, case-insensitive, trim before match. Chạy hoàn toàn trong trình duyệt — không đăng ký, không tải lên.

Danh mục
Sáng tạo
Giá
Miễn phí
Quyền riêng tư
Chạy trên trình duyệt
Đăng ký
Không cần

Quyền riêng tư

Dữ liệu của bạn không bao giờ rời khỏi trình duyệt trừ khi được nêu rõ. Filter Lines chạy hoàn toàn phía client — không tải lên máy chủ, không ghi log, không theo dõi dữ liệu bạn nhập.

Công cụ liên quan

Build, share, and grow on Zerethon Social

Free signup. Earn points, collect achievements, and connect with creators worldwide.

Sign up free