WMS vendor parameters

WMS vendor parameters are non-standard request parameters that are defined by an implementation to provide enhanced capabilities. GeoServer supports a variety of vendor-specific WMS parameters.


The angle parameter rotates the output map clockwise around its center. The syntax is:


where <x> is the number of degrees to rotate by.

Map rotation is supported in all raster formats, PDF, and SVG when using the Batik producer (which is the default).


The buffer parameter specifies the number of additional border pixels that are used in the GetMap and GetFeatureInfo operations. The syntax is:


where <bufferwidth> is the width of the buffer in pixels.

In the GetMap operation, buffering includes features that lie outside the request bounding box, but whose styling is thick enough to be visible inside the map area.

In the GetFeatureInfo operation, buffering creates a “search radius” around the location of the request. Feature info is returned for features intersecting the search area. This is useful when working with an OpenLayers map (such as those generated by the Layer Preview page) since it relaxes the need to click precisely on a point for the appropriate feature info to be returned.

In both operations GeoServer attempts to compute the buffer value automatically by inspecting the styles for each layer. All active symbolizers are evaluated, and the size of the largest is used (i.e. largest point symbolizer, thickest line symbolizer). Automatic buffer sizing cannot be computed if:

  • the SLD contains sizes that are specified as feature attribute values
  • the SLD contains external graphics and does not specify their size explicitly

In this event, the following defaults are used:

  • 0 pixels for GetMap requests
  • 5 pixels for GetFeatureInfo requests (a different min value can be set via the org.geoserver.wms.featureinfo.minBuffer system variable, e.g., add -Dorg.geoserver.wms.featureinfo.minBuffer=10 to make the min buffer be 10 pixels)

If these are not sufficiently large, the explicit parameter can be used.


The cql_filter parameter is similar to the standard filter parameter, but the filter is expressed using ECQL (Extended Common Query Language). ECQL provides a more compact and readable syntax compared to OGC XML filters. For full details see the ECQL Reference and CQL and ECQL tutorial.

If more than one layer is specified in the layers parameter, then a separate filter can be specified for each layer, separated by semicolons. The syntax is:


An example of a simple CQL filter is:



The env parameter defines the set of substitution values that can be used in SLD variable substitution. The syntax is:


See Variable substitution in SLD for more information.


The featureid parameter filters by feature ID, a unique value given to all features. Multiple features can be selected by separating the featureids by comma, as in this example:



The WMS specification allows only limited filtering of data. GeoServer enhances the WMS filter capability to match that provided by WFS. The filter parameter can specify a list of OGC XML filters. The list is enclosed in parentheses: ( ). When used in a GET request, the XML tag brackets must be URL-encoded.

If more than one layer is specified in the layers parameter then a separate filter can be specified for each layer.

An example of an OGC filter encoded in a GET request is:



The format_options is a container for parameters that are format-specific. The syntax is:


The supported format options are:

  • antialiasing (values = on, off, text): controls the use of antialiased rendering in raster output.
  • callback: specifies the callback function name for the jsonp response format (default is parseResponse).
  • dpi: sets the rendering DPI (dots-per-inch) for raster outputs. The OGC standard output resolution is 90 DPI. If you need to create high resolution images (e.g for printing) it is advisable to request a larger image size and specify a higher DPI. In general, the image size should be increased by a factor equal to targetDPI/90, with the target dpi set in the format options. For example, to print a 100x100 image at 300 DPI request a 333x333 image with the DPI value set to 300: &width=333&height=333&format_options=dpi:300
  • layout: specifies a layout name to use. Layouts are used to add decorators such as compasses and legends. This capability is discussed further in the WMS Decorations section.
  • quantizer ((values = octree, mediancut): controls the color quantizer used to produce PNG8 images. GeoServer 2.2.0 provides two quantizers, a fast RGB quantizer called octree that does not handle translucency and a slower but more accurate RGBA quantizer called mediancut. By default the first is used on opaque images, whilst the second is enabled if the client asks for a transparent image (transparent=true). This vendor parameter can be used to manually force the usage of a particular quantizer.
  • timeout: Apply a timeout value for a getMap request. If the timeout is reached, the getMap request is cancelled and an error is returned. The value used for the timeout will be the minimum of this format option and the global WMS timeout defined in the WMS configuration. A value of zero means no timeout.
  • kmattr ((values = true,``false``)): determines whether the KML returned by GeoServer should include clickable attributes or not. This parameter primarily affects Google Earth rendering.
  • legend ((values = true,``false``)): KML may add the legend.
  • kmscore ((values = between 0 to force raster output and 100 to force vector output)): parameter sets whether GeoServer should render KML data as vector or raster. This parameter primarily affects Google Earth rendering.
  • kmltitle: parameter sets the KML title.
  • kmlrefresh ((values = greater than 0 or expires): Force Network Link reload in refresh mode on interval of seconds. When expires is specified client will refresh whenever the time has elapsed specified in cache expiration headers. The caching time may be set in the Layer configuration under Publishing tab setting HTTP Cache Time. This parameter primarily affects Google Earth rendering and is dependent on being respected by the client. Using a second interval is a more reliable choice.
  • kmlvisible ((values = true,``false``)): Indicates whether layers selected will default to enabled or not. Default behavior is enabled. This parameter primarily affects Google Earth rendering.

maxFeatures and startIndex

The parameters maxFeatures and startIndex can be used together to provide “paging” support. Paging is helpful in situations such as KML crawling, where it is desirable to be able to retrieve the map in sections when there are a large number of features.

The startindex=n parameter specifies the index from which to start rendering in an ordered list of features. n must be a positive integer.

The maxfeatures=n parameter sets a limit on the amount of features rendered. n must be a positive integer. When used with startindex, the features rendered will be the ones starting at the startindex value.

Note that not all layers support paging. For a layer to be queried in this way, the underlying feature source must support paging. This is usually the case for databases (such as PostGIS).


The namespace parameter causes WMS GetCapabilities responses to be filtered to only contain layers in to a particular namespace. The syntax is:


where <namespace> is the namespace prefix.


Using an invalid namespace prefix will not cause an error, but the capabilities document returned will contain no layers, only layer groups.


This affects the capabilities document only, not other requests. Other WMS operations will still process all layers, even when a namespace is specified.


It is sometimes advisable (for speed and bandwidth reasons) to downsample the bit depth of returned maps. The way to do this is to create an image with a limited color palette, and save it in the palettes directory inside your GeoServer Data Directory. It is then possible to specify the palette parameter of the form:


where <image> is the filename of the palette image (without the extension). To force a web-safe palette, use the syntax palette=safe. For more information see the tutorial on Paletted Images


The propertyName parameter specifies which properties are included in the response of the GetFeatureInfo operation. The syntax is the same as in the WFS GetFeature operation. For a request for a single layer the syntax is:


For multiple layers the syntax is:


The nature of the properties depends on the layer type:

  • For vector layers the names specify the feature attributes.
  • For raster layers the names specify the bands.
  • For cascaded WMS layers the names specify the GML properties to be returned by the remote server.


Meta-tiling prevents issues with duplicated labels when using a tiled client such as OpenLayers. When meta-tiling is used, images are rendered and then split into smaller tiles (by default in a 3x3 pattern) before being served. In order for meta-tiling to work, the tile size must be set to 256x256 pixels, and the tiled and tilesorigin parameters must be specified.

The tiled parameter controls whether meta-tiling is used. The syntax is:


To invoke meta-tiling use tiled=true.


The tilesorigin parameter is also required for meta-tiling. The syntax is:


where x and y are the coordinates of the lower left corner (the “origin”) of the tile grid system.

OpenLayers example

In OpenLayers, a good way to specify the tilesorigin is to reference the map extents directly.


If the map extents are modified dynamically, the tilesorigin of each meta-tiled layer must be updated accordingly.

The following code shows how to specify the meta-tiling parameters:

 var options = {
     maxExtent: new OpenLayers.Bounds(-180, -90, 180, 90),
 map = new OpenLayers.Map('map', options);

 tiled = new OpenLayers.Layer.WMS(
     "Layer name", "http://localhost:8080/geoserver/wms",
         srs: 'EPSG:4326',
         width: 391,
         styles: '',
         height: 550,
         layers: 'layerName',
         format: 'image/png',
         tiled: true,
         tilesorigin: map.maxExtent.left + ',' + map.maxExtent.bottom
     {buffer: 0}


The scaleMethod parameter controls how the scale denominator is computed by GeoServer The two possible values are:

  • OGC (default): the scale denominator is computed according to the OGC SLD specification, which

    imposes simplified formulas for the sake of interoperability

  • Accurate: use the full expressions for computing the scale denominator against geographic

    data, taking into account the ellipsoidal shape of Earth

The two methods tend to return values rather close to each other near the equator, but they do diverge to larger differences as the latitude approaches the poles.


The interpolations parameter allows choosing a specific resampling (interpolation) method. It can be used in the GetMap operation.

If more than one layer is specified in the layers parameter, then a separate interpolation method can be specified for each layer, separated by commas. The syntax is:


method<n> values can be one of the following:

  • nearest neighbor
  • bilinear
  • bicubic

or empty if the default method has to be used for the related layer.

The parameter allows to override the global WMS Raster Rendering Options setting (see WMS Settings for more info), on a layer by layer basis.