In the advanced digitizing toolbar, QGIS has these 3 tools: Split Features, Split Parts, and Merge Features. Is there a tool or equivalent algorithm for the logical fourth one: "Merge Parts"?

This would have the opposite effect of Split Parts, which takes one part of a multipart feature and splits it into two adjoining parts of the same feature. Conversely, "Merge Parts" would take two (or more) adjoining parts of the same feature and make them a single part of that feature. It would not affect the singlepart/multipart status of the feature (or the layer as a whole).

In the image below there are two multipolygon features, which I realize I should have called Feature A and Feature B (rather than Polygon A and Polygon B). Feature A has 2 parts, and Feature B has 4 parts; note that parts 1 and 2 in Feature B share a common boundary. I've selected Feature B, and I'd like to execute a tool to join parts 1 and 2 into a single part, as shown in the "after" section. Feature B would then still be a multipolygon, but would have only 3 parts instead of 4. enter image description here

The closest I can find is the "merge lines" algorithm; however this would not work with multipolygon features. It also merges all connected parts of a line feature, instead of just selected ones. (Is it even possible to select individual parts?) Is there anything else I'm missing?

  • I should add, there is an easy and fairly obvious workaround, which is to use the Multiparts to Singleparts tool (which makes a new, separate feature out of each part of a multipart feature) and then use Merge Features to re-combine the resulting features (with any adjoining ones being merged into a single part). My question is really whether there is any existing tool that does this by design.
    – Nathan
    Commented Jan 11, 2019 at 17:52
  • Could you draw a sketch about what such merge parts operation would do to support your literal explanation?
    – user30184
    Commented Jan 11, 2019 at 18:03
  • 1
    @MrXsquared: "Merge selected features" requires selecting at least 2 features, which then get merged into one feature. "Merge parts" would perform an operation on only a single feature. "Dissolve" likewise requires combining separate features, not parts of a single feature. And your clarification is correct, I am not trying to do that. I am merging parts of multipolygons, that share a boundary, into a single part of the same multipolygon.
    – Nathan
    Commented Jan 12, 2019 at 2:24
  • 1
    @user30184, I'll see if I can come up with a sketch, but in the meantime, here's an easy way to picture what I'm asking: 1) Select a feature 2) With the Split Parts tool, draw a line through the selected feature 3) You now have separate, adjoining parts of the feature 4) Select "Undo" I'm looking for a tool that does just steps 3-4, without needing steps 1-2.
    – Nathan
    Commented Jan 12, 2019 at 2:28
  • 1
    @Nathan, Contiguous parts are considered a topological error and can be linked with the Fix geometries tool. In my case (QGIS 3.4.3), Split Parts produces always invalid geomeries and I just don't use it. Commented Jan 12, 2019 at 9:05

4 Answers 4


Is there a tool or equivalent algorithm for the logical fourth one: "Merge Parts"?

No, there isn't.

The adjacent parts of a multipolygon are considered a topological error and must be linked with the Fix geometries tool.

Is it even possible to select individual parts?

No, it isn't.

You can select features, not individual parts.

Is there anything else I'm missing?

I don't know. But you can refer to parts of collections with the geometry_n() function in expressions.

For example, you can create a new feature (in a separate layer) with the Geometry by expression tool, that contains the combination of two parts (or more if the function is nested) of a feature or of several, of any layer. If the parts are adjacent, they will form a single part in the new feature.

To create a feature formed by parts 1 and 2, of the feature_ID 0, of the 'multipolygons' layer:

    geometry_n( geometry( get_feature_by_id( 'multipolygons', 0)), 1), 
    geometry_n( geometry( get_feature_by_id( 'multipolygons', 0)), 2)

Note than the Geometry by expression tool copies the table from the input layer. If the input layer have more than one features, more than one features will be created, but only one will have a valid geometry with that expression.


About the WKT of the Multipolygon provided in the comments (https://pastebin.com/1ibYDzR5), I can't seem a line shared by both parts.

When loading the feature in QGIS, it can be seen (with an appropriate zoom level), that the parts are not adjacent.



Be sure to snapping when digitizing and editing (here is the manual). Otherwise, you can not merge those parts as they are in any way.

  • That there is no Merge Parts tool does seem to be the correct answer, thanks! However, it does not seem to be correct that "Fix geometries" will merge parts. I'm unable to reproduce that.
    – Nathan
    Commented Jan 14, 2019 at 3:50
  • @Nathan, If Fix Geometries tool does not merge them, it is because they are not adjacent, or they are not parts of the same feature. If they are adjacent but are not parts of the same feature, but they are in the same layer, the Dissolve tool should also merge them. If they are adjacent but are parts of different features of different layers, the combine() function should merge them. If nothing merge them, they are not adjacent. Commented Jan 14, 2019 at 4:20
  • @Nathan, check your original geometries. It's evident that they have a topological error. If you don't find the error in them, share them and we'll try to look for it together. Commented Jan 14, 2019 at 16:24
  • It's only evident that the fixed geometries have a topological error; the original ones were created with snapping enabled, as you suggest, so they should not. (If they do, it's the result of some further error that's beyond the scope of my question.) Since this data only exists for illustrative purposes, I'd have to re-create it if we wish to explore further.
    – Nathan
    Commented Jan 14, 2019 at 16:42
  • Alternatively, a "split parts" tool that could be used by hand (e.g. click on feature that you want separated by parts) could help us while doing manual edits? I'm struggling to find a tool like that, is there maybe a plugin that can do it?
    – jberrio
    Commented Jan 31 at 23:13

Assuming the features are actually touching I think the best solution is still to use the split features tool followed by the merge selected features tool. Not a one-click solution, unfortunately.


To join singleparts to multiparts, i use the tool "Collect geometries" that i found in the Processing toolbox


For Polygons, Best way I found as a workaround is to use Multi-part to Single Part tool in toolbox.. that makes each part a separate feature.. then using outline symbology for the polygon, align/overlap the borders of the individual features you want to merge.. then use the Merge Features tool by selecting the polygons you want to merge and then Merge..

Before merge of individual parts converted to individual feature/single part.. enter image description here

After merge of individual feature/single parts enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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