csvstack a.csv b.csv

Category: Data Science & Analysis

csvstack a.csv b.csv

Stack two CSVs vertically, header once

csvstack appends the rows of b.csv below a.csv, printing the header once. Both files must share the same column names and order. This is the standard way to combine monthly or per-source exports into one dataset. Add the -g flag to record which file each row came from.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.