How many people did the US have during the civil war?

The total pupulation was 22,000,000 for the union, and 9,000,000 for the confederacy.