Line Tools
Sort lists, remove duplicate and empty lines, add numbers or prefixes, and turn lines into comma lists.
Sort lists, remove duplicate and empty lines, add numbers or prefixes, and turn lines into comma lists.
Handles tasks on multi-line text all at once, such as removing duplicate lines, sorting, deleting blank lines and numbering.
Paste text with one item per line.
Choose the task.
Copy the result.
Choose 'Split by comma' above the input box and leave 'Join' on the result side as 'Line break'. To do the opposite and turn lines into a comma list, choose 'Line break' for splitting and 'Comma + space' for joining.
Yes. Turn on numbering and pick a format such as 1. / 1) / (1) / 1 - / #1 / tab, and you can also type text to add before and after. Numbers and prefix text are added after sorting and duplicate removal are done.
Duplicate removal is case-sensitive by default; turn on 'Ignore case when comparing' to treat Apple and apple as the same line. Choosing 'Numeric order' for sorting puts 2 before 10, while the default alphabetical order sorts by character order.
For a list with numbers mixed in, sorting by character order gives 1, 10, 2, and sorting by numeric value gives 1, 2, 10. For lists of file names or numbered items, check which one you need.
Korean text is sorted in Hangul alphabetical order. You can also reverse the list or shuffle it randomly.
Use it to remove duplicates from a column copied from Excel, clean up blank lines, or add numbers at the start. The feature that adds the same characters before and after each line lets you wrap a list in quotes or add a prefix.
For example, adding a single quote around each line and turning it into a comma-separated list gives the form 'a','b','c', which you can use directly in a database IN condition.
Lists are processed only inside your browser and not sent to a server. Even when you tidy sensitive data such as a list of customer names or emails, it does not leave your device.
Options run in this order: split, trim spaces, remove empty lines, remove duplicates, sort, add numbers and prefix/suffix, then join.
Knowing the order explains why a result looks the way it does. For example, spaces are trimmed first, so lines that differ only by spaces count as duplicates, and numbers are added only after sorting is finished.
Most everyday jobs need only a combination of a few options.
Remove duplicate names
Turn a list of lines into a comma-separated list
Turn a comma-separated list into one item per line
Sort alphabetically
Make Markdown bullet points
Make an HTML list
Make a numbered list
The first occurrence of a line is kept and later identical lines are removed, so the order of your list is preserved as much as possible.
If you turn on the option to ignore case, Apple, apple and APPLE are treated as the same line and only one is kept. The number of removed lines is shown above the result.
When trimming spaces is on, lines that differ only by spaces are also treated as the same line.
If you do not need sorting, leave it on 'No sorting' and your input order stays as it is.
Alphabetical (A–Z)
Reverse
Numeric order
Shortest first
Reverse line order
Shuffle randomly
Alphabetical sorting ignores case, so Apple and apple rank the same.
Set the split rule to comma and a comma-separated line becomes one item per line.
Cells copied across a row in a spreadsheet are separated by tabs, so choose line break, comma or tab as the split rule and everything is split at once.
Type the text to put before and after each line and it is added to every line, finishing repetitive work in one go.
For example, adding an li tag in front and the closing tag after turns a word list into HTML list items right away.
When you turn on numbering, lines are numbered from 1 in the order they appear after sorting.
The default format is '1.', and you can choose another format from the list. The number is placed before the prefix text.
Changing the sort mode also changes the numbering, so finalize the sort first and then turn on numbering.
For quick jobs such as presentation order or cleaning duty, choose 'Shuffle randomly' and press 'Shuffle again'.
Each press gives a new order, but this is not suitable for official draws or anything that needs security. Use it only for casual groups.
When leading spaces carry meaning, such as indentation in code, turn off trimming and then sort or remove duplicates only.
Note that in this case lines that differ by even one space are treated as different, and lines that contain only spaces are filtered out separately by 'Remove empty lines'.
Copying one column separates the items with line breaks, so you can use it as it is. Copying one row separates the items with tabs.
A cell that contains a line break inside it may be split into several lines unintentionally, so compare the input and result line counts to check.
'Use result as input' puts the result into the input box so you can keep processing it with different settings. The original input is replaced, so copy it first if you need it.
'Reset settings' returns every option to its default (trim spaces and remove empty lines on).
Even sensitive data such as lists of names or emails is processed only inside your browser and never sent to a server.
Still, it is safest to clear the input box when you are done and avoid leaving the copied result in documents or messengers.
Keep a copy of the original before removing duplicates so you can recover from a mistake.
Emails copied from an inbox or names of applicants often contain extra spaces, empty lines and duplicates.
Turning on remove duplicates and ignore case on top of the defaults (trim spaces, remove empty lines) gives a clean list in one step.
Kim@a.com
kim@a.com
(empty line)
lee@b.com
With ignore case on, two addresses that differ only by capitalization are treated as the same and only the first is kept.
Sorting by character order puts 10 before 2 (1, 10, 2), but numeric order gives the order people expect: 1, 2, 10.
This is especially useful for file names or episode numbers. For example, Episode 3, Episode 12 and Episode 2 become Episode 2, Episode 3, Episode 12 in numeric order.
It lines up the lines with the fewest characters first, and lines of equal length follow alphabetical order.
It helps when you want to scan short words in a keyword list first, or gather titles that are too long and get cut off at the bottom.
After cleaning a list, the total number of lines is shown above the result, and if you need a character count you can paste it into the character counter.
For example, you can tidy a hashtag list and then count the total characters to check it against a social media limit.
To join many lines into one, set the join to space or comma. To split one line into many, set the split rule to comma or tab and leave the join as line break.
If you want your own separator, choose custom input under join and type any text such as ' | '.
Knowing the usual mistakes in list cleaning saves time you would spend undoing them.
Let's follow the steps of turning a list of fruit names in the order apple, banana, apple, cherry, banana into an alphabetical comma-separated list.
Turning on remove duplicates leaves only apple, banana and cherry. Sorting alphabetically gives apple, banana, cherry. Choosing comma + space for the join returns the result on one line: apple, banana, cherry.
Input
Remove duplicates
Alphabetical sort
Join with comma
If the result is not what you expected because several options are on at once, press 'Reset settings' to return to the defaults and then turn options on one at a time to check.
Remove duplicates and sort are applied in different steps, so turning them on one by one and watching how the result changes makes the cause easy to find.
Copy a column from the sheet, paste it in, add quotes before and after, and join with commas to get a list ready for code or a query.
Paste
Prefix/suffix
Join
When using the result in a query, check that the values do not already contain quotes.
Adding a hyphen and a space before each line gives a Markdown bullet list, and turning on numbering gives a numbered list.
Cleaning up sorting and duplicates before pasting into a document or blog means far fewer corrections later.
Even lists with thousands of lines are cleaned as soon as you paste them. The result updates instantly whenever you change an option, so compare results as you change settings.
The pasted line count and the result line count are shown at the top, so you can see at a glance how many duplicates and empty lines disappeared.
When you are done, check that the difference between input and result line counts matches the number of empty lines and duplicates removed. If the numbers do not match, a line containing a comma was split or an option you did not intend is on.
For important lists, copying the result and checking the first and last few lines by eye catches most mistakes.
You can continue by checking the cleaned list with the character counter or the text comparison tool.
Splitting lines that contain commas by comma can cut them unintentionally, so keep the split rule on line break when you process line by line.
For lists that mix Korean and English, the sort order follows the browser's language rules, so whether Korean or English comes first can differ by environment.