Here's a CSV file of all the cities in the world from OpenStreetMap data. Download now. It's a list of all places that are tagged
First entry is the latitude, second is the longitude, third is the name of the city. Latitude is a number, positive numbers for north of the equator, negative for south. Longitude is a number, positive for west, negative for east. There might be commas in the name of the cities, so some lines have 4 commas.
Since the data is from OpenStreetMap, the data is © OpenStreetMap contributors, and available under Creative Commons Attribution-ShareAlike 2.0 licence (CC-BY-SA). See OSM's copyright & licence page for more information.