Skip To Content


Available with Spatial Analyst license.


Performs either a smoothing (Low pass) or edge-enhancing (High pass) filter on a raster.

Learn more about how Filter works


  • The Low pass filter option is an averaging (smoothing) filter. The High pass filter option is an edge-enhancement filter.

  • Input NoData cells may receive a value in the output if the Ignore NoData in calculations option is checked, provided at least one cell within the filter neighborhood has a valid value.

  • You can use the Focal Statistics tool to create custom filters to your specification.

  • See Analysis environments and Spatial Analyst for additional details on the geoprocessing environments that apply to this tool.


Filter (in_raster, {filter_type}, {ignore_nodata})
ParameterExplanationData Type

The input raster on which to perform the filter operation.

Raster Layer

The type of filter operation to perform.

  • LOWTraverses a low pass 3-by-3 filter over the raster. This option smooths the entire input raster and reduces the significance of anomalous cells.This is the default.
  • HIGHTraverses a high pass 3-by-3 filter over the raster. This option enhances the edges of subdued features in a raster.

Denotes whether NoData values are ignored by the filter calculation.

  • DATAIf a NoData value exists within the filter, the NoData value will be ignored. Only cells within the filter that have data values will be used in determining the output.
  • NODATAIf a NoData value exists within the filter, the output for the processing cell will be NoData. With this option, the presence of a NoData value implies that there is insufficient information to determine the statistic value for the neighborhood.

Return Value

NameExplanationData Type

The output filtered raster.

The output is always floating point.


Code sample

Filter example 1 (Python window)

This example applies a high-pass filter to the input raster.

import arcpy
from arcpy import env
from import *
env.workspace = "C:/sapyexamples/data"
filterOut =  Filter("elevation", "HIGH", "DATA")"C:/sapyexamples/output/filtered")
Filter example 2 (stand-alone script)

This example applies a low-pass filter to the input raster.

# Name:
# Description: Performs a preset focal filter on a raster. 
# Requirements: Spatial Analyst Extension

# Import system modules
import arcpy
from arcpy import env
from import *

# Set environment settings
env.workspace = "C:/sapyexamples/data"

# Set local variables
inRaster = "elevation" 

# Execute Filter
filterOut =  Filter(inRaster, "LOW", "") 

# Save the output"C:/sapyexamples/output/filterout")

Licensing information

  • Basic: Requires Spatial Analyst
  • Standard: Requires Spatial Analyst
  • Advanced: Requires Spatial Analyst

Related topics