Docs in progress for ‘QGIS testing’. Visit for QGIS 2.18 docs and translations.

2.2. Lesson: Adding your first layer

We will start the application, and create a basic map to use for examples and exercises.

The goal for this lesson: To get started with an example map.


Before starting this exercise, QGIS must be installed on your computer. Also, you should have downloaded the sample data to use.

Launch QGIS from its desktop shortcut, menu item, etc., depending on how you configured its installation.


The screenshots for this course were taken in QGIS 3.4 running on Linux. Depending on your setup, the screens you encounter may well appear somewhat different. However, all the same buttons will still be available, and the instructions will work on any OS. You will need QGIS 3.4 (the latest version at time of writing) to use this course.

Let’s get started right away!

2.2.1. basic Follow Along: Prepare a map

  1. Open QGIS. You will have a new, blank map.

  2. Look for and click the Open Data Source Manager button: dataSourceManager

    The dialog allows you to choose the data to load depending on the data type: each tab on the left part of the dialog lists the available data types. You can also browse the files directly from the folder of your computer with the Browser tab (see The Browser Panel section):

  3. Click on the Vector tab, enable the radioButtonOnFile source type and press the browseButton Browse button.

  4. Navigate to the file exercise_data/shapefile/roads.shp (in your course directory). Select the file and click Open. You will see the original dialog, but with the file path filled in. Click Add here as well. The data you specified will now load.


Congratulations! You now have a basic map. Now would be a good time to save your work.

  1. Click on the Save As button: fileSaveAs
  2. Save the map under exercise_data/ and call it basic_map.qgs.

Check your results

2.2.2. moderate Follow Along: Load a layer from GeoPackage

GeoPackage is an open format for storing geospatial data. QGIS adds a lot of support to this new format that is slowly replacing the ESRI Shapefile format.

GeoPackage is a single file format that can contain different types of data: vector and raster layers but also tables without spatial information in them (like CSV file).

In order to load a layer from a GeoPackage:

  1. Click on the dataSourceManager button.
  2. On the left click on the newGeoPackageLayer GeoPackage tab.
  3. Click on the New button and browse to the training_data.gpkg file in the Training Data folder you have downloaded before.
  4. Select the file and press Open. The file path is now added to and shown in the drop-down menu.
  5. Click on Connect button. You should see in the central part of the window the list of all the layers contained in the GeoPackage file.
  6. Select the roads layer and click on the Add button.

Congratulations! You have loaded the first layer from a GeoPackage file.

2.2.3. In Conclusion

You’ve learned how to add a layer and create a basic map!

2.2.4. What’s Next?

Now you’re familiar with the function of the Open Data Source Manager button, but what about all the others? How does this interface work? Before we go on with the more involved stuff, let’s first take a good look at the general layout of the QGIS interface. This is the topic of the next lesson.