Adding data to QGIS
Once you have identified geographical data to work with or a spreadsheet with geographical coordinates (latitude/longitude or easting/northing values) , the next step is to add it to your QGIS project. Our goal is now represent geographical data using a map. We’ll use an extract from the list of schools in Tanzania to demonstrate this.
This is how our sample data looks like as a spreadsheet:

You will notice that the data has several fields/columns: Eastings, Northings, Village/Area, Particulars and Population among others. This data also has 13 records/rows. The first is the column header which defines the content of your rows. Each row represents a feature – remember we defined what a feature is earlier. With the easting and northing values, we can plot the school points on a map.
- First, save the spreadsheet(.xls, .ods or .csv) as a text file (.txt) by renaming the file and changing the the extension (the last three letters after the point).
This is a shortcut to make sure the numbers in the file (Population column) are recognised as numbers (integers or real values data type) and not as text (string data type). If you do not have numbers (excepted your coordinates), the recommended format is .csv.
- Start QGIS. You’ll be able to see a clean project once QGIS is ready for use.

Before we add the list of schools, we need to add a world map (usually called basemap) which will give context to the schools locations. You can add the basemap via the OpenLayers plugin. Once installed, the OpenLayers Plugin will appear under the “Internet” menu item. You can then choose which map you want as the basemap.
- Let’s use the OpenStreetMap basemap, so under Internet > OpenLayers Plugin > Add OpenStreetMap Layer. A world map will be displayed.

- We are now ready to import the .txt file we created from the spreadsheet. Click the Add delimited text layer button
and browse to where you saved the .txt file.

In the dialogue above, you’ll notice that the easting and northing are already detected, this defines the geometry of your features, in case they are not detected, play with the delimiters: comma, tab, space etc until the geometry is detected.
- Click OK, select the correct coordinate reference system as WGS 84 /UTM Zone 36S. You can find it by typing its name in the Filter field.

The Coordinate Reference System (CRS) specifies the transformation relative to the location on earth. What the CRS does is to apply a mathematical formula to your data so that it’s converted from spherical (shape of earth) to a flat surface (your computer screen). So depending on where you are on earth, the CRS will vary. Selecting a wrong CRS may warp your data the wrong way.
Most tiled web maps (such as the OSM maps and Google Maps) use the Mercator projection, EPSG 3857. If you want to create web map tiles and plan to use similar mapping services, this is the right choice. If you are interested in working directly with geographical coordinates or want to transform the coordinates into some other spatial reference system or projection, use the WGS84 (EPSG 4326) reference system, which is the system used by the Global Positioning System (GPS)
- Once you have selected your CRS, you can click OK. You should now see the school layer and points added to the project – you just created a map!

You can zoom in/out using the following tools: 
Sometimes, depending on how clean your spreadsheet is, you may have this warning (no worries, the sample dataset we use is already clean):

This means that the easting/northing values are wrong or have characters like ‘?’, – , space, #, or empty cells and this compromises the quality of your map! The best thing to do is engage in a data cleaning exercise before you continue.
Read more: A Gentle introduction to Data Cleaning
