Site menu:


Site search

QGIS Trace Edit Tool

As you probably know, I love QGIS. It’s a fantastic tool that gets better on an almost daily basis.

However, as with most open source projects, the documentation is often lacking. I found this to be the case when I wanted to use the “Trace Edit” tool. It’s a plugin, and installed using the Plugin Fetch & Manage functionality of QGIS. Just search for “TraceDigitize” in the repositories, and click “Install Plugin.” I assumed that the tool would allow me to make a new feature that ‘snaps’ to an existing feature by tracing along the edge of the existing feature, without having to find and click every vertex. It turns out that this is exactly what the tool does…however I just couldn’t seem to get the tool to work! A Google search turned up nothing except for some developer chats about bugs and QGIS crashing while using the tool. Great!

After some frustration and experimentation, I got the tool to work. So, what’s the secret? First, you must have the “Snapping Options” set (Under Settings > Snapping Options) as the tool requires these settings to know what to snap to. Secondly, you must hold the Ctrl key while digitizing. No, this is not documented anywhere. Until now. If you don’t hold Ctrl, the tool works just like the normal digitizing tool.

Trace Edit Tool

Trace Edit Tool

One thing to note is that if your snapping tolerance is too small, or you go too fast as you trace, you will still end up with gaps as in the example above. Try tweaking (increasing) the snapping tolerance, or slow down a bit, and you should be fine!



Pingback from DARREN COPE » QGIS Topological Editing
Time October 19, 2011 at 8:02 am

[…] a previous post (QGIS Trace Edit Tool) I discussed how to use QGIS’ trace edit plugin to create a polygon adjacent to an existing […]

Comment from Ed
Time February 1, 2012 at 8:27 am

I can’t find this plugin. Can you help?!

Comment from Ed
Time February 1, 2012 at 8:31 am

Found it, I had filtered out the ones marked as experimental, which this is.

Comment from darrencope
Time February 1, 2012 at 2:29 pm

Ed; glad you found it. Good point about the experimental plugins! I’m sure your comment will help others that can’t find it!

Comment from Zak Baron
Time February 1, 2012 at 4:08 pm

Hi Darren,
Thanks. I didn’t know about the plug-ins beyond what was already there on the list. I was looking for a trace tool that could be used to re-shape part of a feature to match another feature. Will this tool do that or does it only work to trace a new feature? I do have snapping enabled and I am holding the control key…
Even if this isn’t what I’m after, I appreciate the tip on finding and loading plug-ins.

Comment from darrencope
Time February 3, 2012 at 7:15 pm

Hi Zak,

I’m not 100% sure I understand your questions. Give it a try, and if it doesn’t work, write me back with some more details!

Comment from Zak Baron
Time February 13, 2012 at 10:17 am

Hi Darren,
I thought I bookmarked your site, but I lost it.
So, it turns out that the tool I was looking for is the ‘reshape features’ tool on the advanced editing toolbar. As you said in your post above the plugin allows you to make a new feature that snaps to an existing one–I wanted to modify the edge of an already existing feature to match the edge of another existing feature with a tracing tool. I can’t believe I have used Qgis as much as I have in the last 6 months and never saw the ‘advanced editing’ toolbar…

Comment from darrencope
Time February 13, 2012 at 11:35 am

Hey Zak,

Glad you got that sorted out! There are some neat tools on the Advanced Editing Toolbar :)

Comment from Darryl Klassen
Time April 11, 2012 at 11:56 am

Hi Darren, i can’t seem to find this plugin either. Under Plugins menu, i have ‘Fetch Python Plugins’ and ‘Manage Plugins’, neither of which has a search option. I am running Quantum GIS (v 1.7.3 Wroclaw).

Comment from darrencope
Time April 11, 2012 at 12:00 pm

Hi Darryl,

If you open “Fetch Python Plugins” you will get a list with a “Filter” box at the top. In the “Filter” box, type ‘trace’ and you should see it show up in the list below. Select it, and hit Install Plugin.

Comment from Darryl Klassen
Time April 11, 2012 at 12:37 pm

Thanks for the quick reply Darren. I did this and got the Contour Plugin 0.9.1 as the only option (is the correct one?). When i installed it, it told me that it was broken. And didn’t actually give me any new tools/menus. Do you have the URL of the repository this plugin comes from?

Comment from darrencope
Time April 11, 2012 at 12:45 pm

Darryl; That’s odd! Both the contour plugin and the Trace plugin are in the same repository (QGIS Contributed Repository) so if you see one, you should see both! Try going to the “Repositories” tab and click “Add 3rd Party Repositories” then try the filter again?

Comment from Darryl Klassen
Time April 11, 2012 at 12:54 pm

Same result – only the contour plugin showed up. Do you think it is a version issue? When i go to the repository location ( i do see the the traceDigitize. Is there a way i can install this from the zip file i download from there?

Comment from Darryl Klassen
Time April 11, 2012 at 12:57 pm

I think i figured it out, i downloaded the ZIP file for the traceDigitize and placed the folder in the qgis python plugins folder – restarted Quantum and it showed up in my manage plugins menu. Thanks for your help.


Comment from darrencope
Time April 11, 2012 at 1:03 pm

Great news Darryl! Yes, you can ‘manually’ install any plugin that way–glad you figured it out :) I have no idea why it wasn’t showing up in your list though; that’s odd!

Comment from Rupes
Time June 25, 2012 at 10:10 am

Hi, Daryl and Darren. Recent redundancy with supported MAPinfo IT forced me into QGIS to do my mapping. But very frustrated not being able to snap polygons to purchased maps.gml. At least 3 days trying to figure it now thinking I’ll buy map info!
Had same issue as Darryl, only contour viewable where do you find the zip file and how do you load manually – is it a Mac issue not showing. Using OS x 10.7.4 and latest QGIS – I used to love drafting a neat map!!

Comment from Rupes
Time June 25, 2012 at 11:35 am

Thanks Darren, Managed to find the trace and digitise tool and works with a mac holding down cmd. But it is vicious. Seems to snap to any line, tiny deviation when following a parallel line like a ditch and it is hoping from one side to the other, Treid changing scales and tolerances but some pointers as to how to control this aspect would be well appreciated. Many thanks for getting me the tool though – nearly 2 weeks on and off to get that tool loaded. Rupes

Comment from darrencope
Time June 25, 2012 at 2:58 pm

Hi Rupes,

It should only snap to the layers you have checked off under Settings > ‘Snapping Options’ – did you check that?

Comment from Ashok
Time August 9, 2012 at 5:53 am

Thanks Darren

Comment from anupama
Time August 15, 2012 at 11:14 pm

I am using contour plugin 0.9.1 to draw contours of a vector point layer. But the plugin does not work when the number of points increases beyond 50. It was not the case when i was using contour plugin 0.5. I have searched the net but could not get the older version. where shall i get it. How do i draw contours if i have a large number of points. Please help me.

Comment from anupama
Time August 15, 2012 at 11:16 pm

help me to draw contours using contour plugin 0.9.1 for a large no. of points.

Comment from darrencope
Time August 23, 2012 at 3:44 pm

@anupama: have you tried with a different dataset? I’ve personally never used that plugin, so am not sure what to say. If you still can’t get it to work, perhaps consider asking over at

Comment from Mike
Time April 10, 2013 at 5:44 pm

Hello Darren,

I am just installed the traceDigitze plug in from the experimental depository in QGIS 1.9.0 Lisboa. I tried to use the tool to trace a line shapefile along another line shapefile and it traces, but when I right click to edit the edit, I get the following error. Have you ever come across this:

An error has occured while executing Python code:

Traceback (most recent call last):
File “C:/Users/mike.macrae/.qgis//python/plugins\traceDigitize\”, line 236, in canvasReleaseEvent
File “C:/Users/mike.macrae/.qgis//python/plugins\traceDigitize\”, line 282, in sendGeometry
layerEPSG = layer.srs().epsg()
AttributeError: ‘QgsVectorLayer’ object has no attribute ‘srs’

Python version:
2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)]

QGIS version:
1.9.0-Master Master, 9247262

Python path: [‘C:/OSGeo4W/apps/qgis-dev/./python’, ‘C:/Users/mike.macrae/.qgis//python’, ‘C:/Users/mike.macrae/.qgis//python/plugins’, ‘C:/OSGeo4W/apps/qgis-dev/./python/plugins’, ‘C:\\qgis_scripts’, ‘C:\\OSGeo4W\\bin\\’, ‘C:\\OSGeo4W\\apps\\Python27\\DLLs’, ‘C:\\OSGeo4W\\apps\\Python27\\lib’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\plat-win’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\lib-tk’, ‘C:\\OSGeo4W\\bin’, ‘C:\\OSGeo4W\\apps\\Python27’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\site-packages’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\site-packages\\PIL’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\site-packages\\win32’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\site-packages\\win32\\lib’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\site-packages\\Pythonwin’, ‘C:\\OSGeo4W\\apps\\Python27\\lib\\site-packages\\wx-2.8-msw-unicode’, ‘C:\\OSGeo4W\\apps\\qgis-dev\\python\\plugins\\fTools\\tools’]

Comment from Yasmine
Time May 4, 2013 at 6:05 pm

Thanks for this information. Unfortunately, it does’nt work for me. I have installed and selected the plugin but it doesn’t change anything… I don’t understand …I use Q Gis1.8.
Do you have an idea to help me?
Thanks anyway.

Comment from darrencope
Time May 6, 2013 at 7:56 am

Yasmine; at what part are you having issues? Install and activate the plugin. Enable snapping, click the Tool on the edit toolbar, and hold Ctrl to trace.

Comment from Caitlin
Time September 21, 2013 at 11:09 am

Hi Darren,

I am having the same problem as Darryl Klassen – cannot get the plugin to show up on the installer. I have downloaded the zip file but can’t figure out where to put it to make it show up. I am using OSX10.8.4 and QGIS 2.0.1. Help! Thanks!

Comment from darrencope
Time September 23, 2013 at 7:20 am

Hi Caitlin. Unfortunately, the Trace Edit plugin has not yet been converted to QGIS 2.0. See: You should still be able to use it in an old version of QGIS if you need it.

Pingback from Problems with QGIS plugin traceDigitize on Mac? | Question and Answer
Time November 16, 2013 at 11:48 pm

[…] trying to get the traceDigitize plugin to work with QGIS 2.0.1 on my Mac while following this tutorial but I get this error as soon as I […]

Comment from Mapper
Time February 3, 2014 at 12:13 am

Hi, The Plugin got installed. “Trace Edit” icon got showed up in the “Digitizing toolbar”. I set the snapping options in the settings and toggled to editing mode. But the “trace edit” icon is not active and can’t take the tool.

Comment from darrencope
Time February 3, 2014 at 9:31 am

Mapper; If the layer is editable and selected in the legend, you should be able to use the tool. What exactly do you mean by ‘can’t take the tool?”

Comment from Bill
Time February 12, 2014 at 4:50 am

I am using QGIS on a Mac. I cannot get the Capture points, line or polygon icons to appear?

Comment from darrencope
Time February 12, 2014 at 8:10 am

Bill, I’m not sure what you mean by “Capture Points, line or polygon” icons. Is your layer editable, and do you have it selected in the legend?

Write a comment