By some reason SAGA does not appear into Processing Toolbox list although I have checked it to be active. See screen capture. What could be the problem?

QGIS vesion is 2.18.2 and OS is Ubuntu 16.04 (Xenial).

problem to get SAGA to be seen in Processing Toolbox list

  • I have the same problem with QGIS 2.14 in Ubuntu 16.04 (Xenial). I run "saga_cmd" on the terminal and I see that the installation is correct: "SAGA Version: 2.2.7". I have reinstalled SAGA several times but I still have the same error. QGIS indicates that SAGA 2.2.7 is not supported but on another computer with Kubuntu it works. ![enter image description here](i.sstatic.net/9Yilk.png) Commented Jan 20, 2017 at 10:12

6 Answers 6


Note: On 16.04, the default Ubuntu repositories for Xenial only include QGIS 2.8 Wein. The Q version we want is QGIS 2.18 Las Palmas (the current release as of the date of this post), which includes the version of the SAGA algorithm and API that the below solution works with. To remedy this situation, add the line deb http://qgis.org/debian xenial main to your /etc/apt/sources.list file and follow instructions to add the public repository key, then sudo apt-get update to get the updated source list. Then follow the steps as below.

I tried several things before I got this to work properly. First I tried both Jesus's answer and AndreJ's answer as shown below, then added my own solution. The solution I came up with ends up being kind of hacky, but it works. Some of these steps may be superfluous:

  1. Added the line deb http://ftp.ussg.iu.edu/linux/ubuntu xenial main universe to the /etc/apt/sources.list file.
  2. Removed SAGA, QGIS and associated dependencies:

    $ sudo apt-get purge saga libsaga qgis; sudo apt-get autoremove;
  3. Installed proper SAGA version using:

    $ sudo apt-get update; sudo apt-get install saga=2.2.3+dfsg-1build1 libsaga=2.2.3+dfsg-1build1
  4. Then tell apt not to touch saga and libsaga when installing updates

    $ sudo apt-mark hold saga libsaga
  5. Reinstalled Q:

    $ sudo apt-get install qgis
  6. At this point I was still not seeing the SAGA plugin. I decided to poke around in /usr/share/qgis/python/plugins/processing/algs/saga because I was desperate. I found the following statement in /usr/share/qgis/python/plugins/processing/algs/saga/SagaAlgorithmProvider.py beginning on line 76:

    if not version.startswith('2.3.'):
                           self.tr('Problem with SAGA installation: unsupported SAGA version found.'))

    Because the version we now have is 2.2.3, I modified line 76 to be:

    if not version.startswith('2.'):

    Then I restarted Q, and it works! Thank you Jesus and AndreJ for the help. Upvoted for providing a terrific lead to follow.


If you look into the code at https://github.com/qgis/QGIS/blob/master/python/plugins/processing/algs/saga/SagaAlgorithmProvider.py you will see that SAGA up to version 2.2.3 is supported.

The main Ubuntu repository still has SAGA 2.2.3 for Xenial (which works for me on Linux Mint 18 too), while Ubuntugis stable has SAGA 2.2.7 which seems to fail with the QGIS processing plugin.

See https://hub.qgis.org/issues/13279 on the problems between SAGA versions and QGIS processing.

Apart from that, you still might have a version of processing as an external plugin. These were located under ~/.qgis2/ python/plugins/processing/

Make sure to remove that folder to avoid any interfering between the current core and the outdated external version of the plugin.

  • Thanx for all answerers. Can I just install SAGA 2.2.3 from Ubuntu repository or should I somehow first uninstall SAGA 2.2.7?
    – Estiivan
    Commented Jan 24, 2017 at 9:54
  • Surely you have to remove, autoremove and purge the packages from Ubuntugis, and remove the ppa entries before re-installing. Two versions in parallel are not possible under Linux.
    – AndreJ
    Commented Jan 24, 2017 at 15:49

Finally I solved the problem. Here's what I did:

1: I installed SAGA 2.2.3 with your dependencies:

sudo apt-get install saga=2.2.3+dfsg-1build1 libsaga=2.2.3+dfsg-1build1

And I make sure that I have version 2.2.3 with saga_cmd.

But SAGA still did not appear in the toolbox

2: According this link, I had a ~/.qgis2/python/plugins/processing/algs/saga folder. I remove ~/.qgis2 and everything ok.

I reinstall the add-ons and I already have the new .qgis2 folder.

Now SAGA is in processing toolbox! Thanks @AndreJ.!

  • You may want to add that in order to make this command work, users should add a dependency to the /etc/apt/sources.list file. The line deb http://ftp.ussg.iu.edu/linux/ubuntu xenial main universe worked for me
    – Ian
    Commented Jul 5, 2017 at 21:58

Don't get worried. All you need to do is install SAGA on your system. It happened in my System as well. I tried many suggestions available on the internet but without success. I was really confused about what to do and I thought it would be very difficult.

Then Luck favored me. I thought I would give a try by myself.

I simply wrote this on my terminal and ran it.

sudo apt install saga

And there it is. It works. The simplest solution to that problem is found.

All the best.


Same error: Ubuntu 16.04 and QGIS 2.18.3. It's enough to change line 76 in /usr/share/qgis/python/plugins/processing/algs/saga/SagaAlgorithmProvider.py like this:

  if not version.startswith('2.2.'):

And Saga is back in Toolbox.

  • Hi, what SAGA did you installed? 2.3.1? How did you installed it? Thanx
    – ilFonta
    Commented Dec 27, 2018 at 22:50

I had the same problem, to solve just compile the 2.2.3 version of saga (do not install from ubuntugis). It works with these configuration:

  • QGIS 2.14-ltr needs SAGA 2.2.3
  • QGIS 2.18-ltr needs SAGA 2.3.1

Just have to compile SAGA from source (link to version download), DO NOT install from any repository. This works with ltr qgis repository too.

  • Hi CaMa, sorry for the redundant question. I have QGIS 2.18.22 (ltr). Do I have to compile the SAGA 2.3.1? Thanx
    – ilFonta
    Commented Dec 27, 2018 at 22:44
  • Hi, I have QGIS 2.18.27 (Ubuntu 18.04-ltr OS) and SAGA 2.3.1 is working.
    – CaMa
    Commented Jan 7, 2019 at 15:54

Not the answer you're looking for? Browse other questions tagged or ask your own question.