Skip to content
© 2026 The ThingsBoard Authors
Try for free

ThingsBoard Cloud

Choose your data region

Your data stays in the region you choose, for residency and compliance. No credit card required.

Rather run it yourself? Install on your own servers

Filters

Filters narrow which entities a widget displays by defining conditions on entity attributes or telemetry keys — only entities matching your criteria appear in the widget.

Filters are defined at the dashboard level and then assigned to individual widget data sources.


  1. In edit mode, click Filters in the toolbar, then click Add filter.
  2. Enter a Filter name. Toggle Editable to allow end users to modify the filter in view mode.
  3. Click Add key filter, then set the Key type, Key name, and Value type for the condition. In the filters table below, choose an Operation and enter a Value, then click Add.
  4. Repeat to add more key filters — use the And/Or toggle to control how they combine. The Filter preview shows the resulting expression as you build it.
  5. Click Add to save the filter, then Save in the Filters dialog to apply it to the dashboard.

Each key filter is defined by three fields at the top:

Field Description
Key type Type of entity data to filter on: Time series, Attribute, Entity field, etc.
Key name Name of the telemetry key or attribute (case-sensitive).
Value type Data type of the value: Numeric, String, Boolean, etc.

Inside a key filter, use the Add and Add complex buttons to define conditions:

  • Add — adds a simple comparison operation (e.g., greater than 30). Multiple simple operations are joined with AND.
  • Add complex — adds a group of sub-conditions joined by either AND or OR. Use this for range queries or union conditions.

Complex conditions can be nested to express patterns like (A AND B) OR (C AND D).

Example — temperature between 10 and 30:

  • Operation 1 (Add): greater than 10
  • Operation 2 (Add): less than 30
  • Both joined with AND automatically.

Example — battery level below 10% or above 95%:

  • Add complex, set operator to OR
  • Sub-operation 1: less than 10
  • Sub-operation 2: greater than 95

By default, comparison values are static. To use a runtime attribute as the threshold instead, set the Dynamic source type:

Option Description
No dynamic value Use a static hardcoded value (default).
Current tenant Read the threshold from a tenant attribute.
Current customer Read the threshold from the current customer’s attribute.
Current user Read the threshold from the current user’s attribute.

When a dynamic source is selected, a Source attribute field appears — enter the attribute name whose value serves as the threshold. This lets different users or customers see filtered results based on their own attribute values.

Each operation row has a gear icon that opens the Edit filter predicate user parameters dialog, which controls how the operation value is exposed to dashboard users at runtime:

Parameter Description
Editable When enabled, users can change this filter value directly from the dashboard without entering edit mode.
Custom label Custom display label for the filter condition. When disabled, a label is generated automatically (e.g., temperature greater than).
Display order Order in which this predicate appears in the filter panel shown to users.
Unit Opens unit settings: source unit, optional unit conversion, and target units for metric, imperial, and hybrid systems.

A filter takes effect only when assigned to a widget’s data source:

  1. Open the widget for editing.
  2. In the Data tab, find the data source row.
  3. Click the Filter field and select the desired filter.
  4. Apply and save changes.

Each widget data source can use only one filter at a time.


Each filter in the Filters dialog has an Editable toggle. When enabled, users without dashboard edit access can switch the active filter from the toolbar at runtime. Disable it to lock the filter for all non-editors.

This is separate from the per-operation Editable setting in Filter predicate user parameters, which controls whether users can change the threshold value of a specific operation.