I am using GRASS GIS 7.2.0. The intent is to clip my DEM raster. I have searched available raster tools but didn't found anything allow me to clip my raster using polygon vector or interactively.

How would I clip my raster in GRASS GIS? Is there any plugin or tool to do the job?

  • grasswiki.osgeo.org/wiki/Cropping_maps Commented Jan 30, 2017 at 4:42
  • @Ben your link is claer about the istructions "Make boundary into mask using r.mask then copy raster source to new map (g.copy). All cells outside of the mask will be omitted from the new copy." but in my case I can see that the behavior is not the expected, it is copying everything. Wrong or new behavior of g.copy? I am running GRASS GIS 7.2.0 (64bit) on windows 7
    – Marco
    Commented Sep 26, 2017 at 13:30

2 Answers 2


For cropping a raster map according to a vector map, you can use r.mask which also supports vector maps.

Update 2018: Meanwhile there are v.clip and a new Addon r.clip available.

  • "r.mask - Creates a MASK for limiting raster operation, Areas inside the MASK are not hidden; areas outside the MASK will be ignored until the MASK file is removed". I am intending to produce separate clipped raster instead. For the purpose r.mask doesn't provide the solution.
    – Dave
    Commented Mar 14, 2018 at 5:43

I know it's late, but for others who have the same question. Please try this:

# limit your computational region to polygon_vector
r.mask vect=polygon_vector

# clip big_raster to polygon_vector (MASK set by r.mask above)
r.mapcalc ex=clipped_raster=big_raster

# export
r.out.gdal input=big_raster output=clipped_raster.tif

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.