Comparison template functions

These template tests let you compare values in your templates. Use them inside if conditions and filters to check equality, order, or membership.

Home Assistant extends the Jinja2 template engine with many custom functions, filters, and tests. Each function on this page has its own page with detailed descriptions, parameters, and practical examples.

New to templates? Start with the templating documentation to learn the basics.