CSV Sorter

Sort CSV rows by any column, A to Z or Z to A, as text or as numbers, and copy the sorted CSV.

Processed on your device. Files are not uploaded

How to sort a CSV file

  1. Paste your CSV

    The header row stays at the top.

  2. Pick the column

    Type its name or its number.

  3. Choose the order

    A to Z or Z to A. Tick Sort as numbers to sort by value.

    Text is sorted naturally, so item 10 comes after item 9.

Worked example

This is what CSV Sorter gives for its own sample values. Open the tool above and change anything to try your own.

CSV

name,team,city,age
Ada,Platform,London,36
Linus,Kernel,Helsinki,54
Grace,Compilers,New York,85
Ada,Platform,London,36
Alan,Research,London,41
Delimiter
Detect automatically
Sort by column (name or number)
1
Order
A to Z, smallest first
Sort as numbers
No

Sorted CSV

name,team,city,age
Ada,Platform,London,36
Ada,Platform,London,36
Alan,Research,London,41
Grace,Compilers,New York,85
Linus,Kernel,Helsinki,54

About CSV Sorter

Sort CSV rows by any column. Text is sorted naturally, so item 10 comes after item 9, and the number option sorts by value.

FAQs

Does it keep the header row?

Yes. The first row is always the header.

How do I sort numbers properly?

Turn on Sort as numbers.

Can I remove duplicates too?

Use CSV Duplicate Remover.

Related tools