How to Use Esri File Geodatabases in QGIS

Caitlin Dempsey

Updated:

Esri’s file geodatabase (GDB) is a proprietary data storage format designed for managing, querying, and analyzing spatial and non-spatial data within the ArcGIS software ecosystem. As the name implies, a file geodatabase is a series of files stored in within a folder. The folder name is appended with the extension .gdb.

Esri file geodatases can be used to store vector and raster GIS datasets.

A screenshot of a file geodatabase folder.
An example of the folder and file structure of an Esri file geodatabase.

Despite the proprietary nature of Esri file geodatabases, these geospatial datasets can be viewed within QGIS using GDAL drivers. Here are instructions for how to view both vector and raster GIS data that is stored in file geodatabase format in QGIS.

Viewing vector file geodatabase in QGIS

Viewing a vector file geodatabase is pretty easy in QGIS. To do so, navigate to the folder where a file geodatabase is stored. The folder will be in the format of: <foldername>.gdb.

Method 1: Drag and drop vector file geodatabases into QGIS

Simply grab the .gdb folder and drop it into the layers pane or the map canvas area in QGIS. Your computer’s cursor will turn into a green plus sign when you hover the dragged folder into either of these two areas.

A screenshot showing a folder bring dragged into QGIS
Vector file geodatabases can be simply dragged and dropped into a QGIS map project.

Method 2: Use the Add vector layer option

Alternatively, you can use the add vector layer option to load the file geodatabase into QGIS.

To start, file select Layer from the top QGIS menu item. Then select Add Layer -> Add Vector Layer… from the menu.

Screenshot showing how to find the Add vector layer option in QGIS.
The Add vector layer option can be accessed from the Layer menu in QGIS.

This will launch the Data Source Manager interface in QGIS. Select “Directory” as the source type as the file geodatabase is a collection of file stored in a folder with a .gdb extension.

In the Source section, select “OpenFileGDB”. Next click on the … to the right of the Vector Dataset(s) information box and navigate to the location on your computer where the file geodatabase folder is stored. When you have set the file pathname, click on the “Add” button located at the bottom right of the interface.

Screenshot of the Data Source Manager interface in QGIS.
Data Source Manager interface in QGIS.

Once the file geodatabase has been loaded into QGIS, the GIS data can be symbolized, have labels applied, and have the attribute information queried. The file geodatabase is view only so you will not be able to edit the GIS data that it contains. To do so, you would need to export the dataset into a file format that QGIS can edit.

A screenshot of a map view with point locations in green labeled with the college name.
A file geodatabase in QGIS.

Viewing a raster file geodatabase in QGIS

Viewing a raster file geodatabase in QGIS is dependent on the version of GDAL that you have installed. The ability to load read access raster file geodatabases was added to GDAL versions 3.7 or higher. If you are running an instance of QGIS with a lower version of GDAL you will not be able to view raster file geodatabases.

Error message trying to load a raster file geodatabase

If you try to drag and drop a file geodatabase into QGIS with a version of GDAL that is under 3.7 you will be presented with this error message: Invalid Data Source: /<file pathname>/<geodatabase name>.gdb/ is not a valid or recognized data source.

Screenshot of an error message with a red background in QGIS.
If your version of GDAL is not 3.7 or higher, you will incur this error message trying to load raster file geodatabases into QGIS.

Checking the version of GDAL in QGIS

To check your version of GDAL that was installed with QGIS, go to the QGIS menu item and select about. There a list of the QGIS version along with installed packages and versions are listed.

Running too low of a version of GDAL is particularly problematic with Mac OS users of QGIS. A note on the QGIS download page states, “The Mac packages are currently behind waiting for renewed certificates.”. The most recent version of QGIS 3.36,.3 named Maidenhead. A look at the About page for this version shows that GDAL is only at 3.3.2.

Screenshot of the QGIS About page.
Screenshot of the QGIS About page.

A workaround is to use the experimental installer to install a more up-to-date version of QGIS along with more updated versions of the various packages that supplement QGIS. To do this visit the Github page that hosts the QGIS installer packages from conda.

From there, select the Mac OS version and run the installation package. As these are experimental installers, the installation process is not always smooth or without instability issues. Once installed, a look at the About page for QGIS shows more up-to-date packages along with a more recent version of QGIS.

The about page of QGIS with more current packages installed.
The about page of QGIS with more current packages installed.

Adding rector file geodatabases in QGIS

Once you have a version of QGIS installed that is running GDAL version 3.7 or higher, you can either use the drag and drop method to add a raster file geodatabase or use the Browser pane to add it.

Using Browser to add a raster file geodatabase

The Browser is similar to the Finder tool for Mac OS or Windows Explore on a PC. This pane in QGIS lets you navigate through your computers file folder structure. To add this page go to View –>

Screenshot showing how to get to the Browser pane option.

Once the Browser pane is turned on, you can then use it to navigate to the raster file geodatabase folder. The file geodatabase will have an icon of a drum with an arrow to the left of the icon. If you click on the arrow, any raster datasets stored within the file geodatabase will be shown with the checkerboard raster icon.

Screenshot of a geodatabase icon.

Grab the raster file and drag it down into the layers pane. The raster file geodatabase will then load in QGIS.

As the the vector file geodatabase, this is read access only. You can stylize the file geodatabase but you will not be able to edit the file.

To be able to edit the raster database you will have to first export the data to a file format that QGIS can edit. Right click on the file geodatabase in the Layers pane and select export and then chose a raster GIS data format from the select. Then load that exported file into QGIS to do any edits.

Screenshot of a raster file geodatabase in QGIS.
A raster file geodatabase in QGIS.

More QGIS tutorials

Photo of author
About the author
Caitlin Dempsey
Caitlin Dempsey is the editor of Geography Realm and holds a master's degree in Geography from UCLA as well as a Master of Library and Information Science (MLIS) from SJSU.