# OpenLayers WFS Protocol with Filter

# WFS Protocol and Filter

filter, wfs, comparison

Demonstrates the use of a filter in making GetFeature requests using the WFS protocol.

If a vector layer has a filter and the protocol supports server-side filtering, the filter will be serialized in requests for features. The WFS protocol can be used with a vector layer to serialize a filter using OGC Filter Encoding. This example requests all features that are `TYPE` "highway" or "road".

See the wfs-filter source for details on how this is done.