How to Show Filters on Power BI Report
In this article
You can show filters on a Power BI report by using the Filter pane, visual-level filters, page-level filters, and report-level filters. These tools allow you to restrict the data displayed in visuals to specific categories, dates, or numeric ranges. Before you begin, ensure you have the Power BI Desktop application installed and a report file (.pbix) loaded into the workspace.
What You'll Need
- Power BI Desktop installed on your computer.
- A valid Power BI account or a workspace where you have edit permissions.
- A report file (.pbix) containing the data you wish to filter.
Step-by-Step
- Open the Report Layout. Launch Power BI Desktop and open the report you want to modify. By default, the left-hand pane is the Report canvas where visuals are placed. To the left of the canvas is the Fields pane, and to the left of that is the Filter pane. If you do not see these panes, go to the View tab on the ribbon at the top and ensure the Filters and Fields checkboxes are ticked.
- Locate the Filter Pane. Find the Filter pane on the far left side of the screen. It is usually collapsed by default. Click the arrow next to Filters to expand it. You will see three sections: Report, Page, and Visual. These sections correspond to the scope of the filters.
- Add a Report-Level Filter. Report-level filters apply to the entire report. In the Filter pane, click on Report to expand it. You will see a list of fields (columns) from your data model. Click on the field you want to filter, such as Region or Date. A filter window will appear. Select Basic filters and choose an operator, such as Equals or Contains. Then, select the specific values you want to include. For example, select Equals and check North America. This will filter all visuals on the report to show only data for North America.
- Add a Page-Level Filter. Page-level filters apply only to the current page, not the whole report. In the Filter pane, click on Page. This section will be empty initially. Drag a field from the Fields pane into the Page section of the Filter pane. A filter window will open. Set your criteria here. For instance, you might filter the Year field to show only the current fiscal year. This ensures that only the visuals on this specific page reflect this new restriction.
- Add a Visual-Level Filter. Visual-level filters are the most granular. They apply only to a single visual on the canvas. Click on a visual, such as a bar chart or a card. In the Filter pane, click on Visual. You will see a list of fields that are used in that specific visual. Click on the field you want to filter. A filter window will appear. Set your criteria. For example, if you have a bar chart showing sales by product, you can filter the Product field to show only top-selling items. You can use the Top N operator to show the top 10 products by sales amount.
- Use the Quick Filter on a Visual. You can also add filters directly to a visual without using the pane. Click on a visual to select it. In the top-right corner of the visual, look for the Filter button (usually a funnel icon). Clicking this opens a filter pane dedicated solely to that visual. This is useful for quick ad-hoc analyses. You can change the filter type from Basic filters to Top N, Slicer, or Advanced filters.
- Save Your Work. Once you have applied your filters, it is important to save the report. Go to the File menu and select Save (or Save As if you are saving to a new location). Your filters are now part of the report file and will be applied whenever the report is opened.
Common Mistakes
One common mistake is confusing the scope of filters. Users often apply a report-level filter when they only want to affect one page. This can lead to unexpected results where data disappears from other pages. Always check the Report, Page, and Visual sections of the Filter pane to ensure you are filtering in the right place.
Another mistake is failing to understand the data model. Filters are applied based on the fields in your data model. If you try to filter by a field that is not in the model, the filter pane will not show it. Ensure you are dragging the correct field from the Fields pane into the Filter pane.
Users also sometimes forget to save their work. Power BI Desktop does not automatically save every change. If you close the application without saving, you will lose all your filter configurations. Always save your report frequently.
Tips
Use Advanced filters for complex logic. The Basic filter operator is limited to simple comparisons like equals, greater than, or less than. If you need to filter by a date range, use the Between operator. If you need to filter by multiple conditions, such as Region is North America AND Year is 2023, use the And or Or operators in the Advanced filter section.
Organize your filters by grouping them. You can create groups in the Filter pane to keep related filters together. For example, you can group all date filters under a Date group and all geographic filters under a Geography group. This makes it easier to manage complex reports with many filters.
Use Slicers for interactive filtering. Slicers are visuals that allow users to filter the report by clicking on buttons or selecting ranges. You can add slicers to your report by dragging a field from the Fields pane onto the canvas. Slicers are a great way to make your report more interactive and user-friendly.
Troubleshooting
If your filters are not working, the first step is to check the scope. Ensure you are looking at the right section of the Filter pane. If you are trying to filter a visual, but the filters are not affecting the visual, check if the visual is using a field that is not in the list of available fields in the Visual section of the Filter pane.
Another common issue is data refresh. Filters are applied to the data that is currently loaded in Power BI Desktop. If you have a live connection to a dataset, you may need to refresh the data to see changes in the underlying data source. Right-click on the dataset in the Home ribbon and select Refresh.
If you are using a DirectQuery connection, filters are sent to the data source. This can sometimes cause performance issues if the data source is slow to respond. Try optimizing your data model or reducing the amount of data being queried.
If you cannot find a field in the Filter pane, check if the field is hidden. You can hide fields in the Fields pane by right-clicking on the field and selecting Hide from fields pane. If a field is hidden, you may still be able to use it in visuals, but you cannot filter by it in the Filter pane. To unhide the field, go to the Modeling tab on the ribbon and select Show Fields.
Frequently Asked Questions
Do filters persist when I publish the report?
No, the filters you set in Power BI Desktop are not published to the Power BI service. Filters are only applied when the report is opened in the Desktop application. In the Power BI service, filters are typically applied by individual users through slicers or the Filter pane within the report viewer.
Can I filter by multiple values at once?
Yes, you can filter by multiple values. In the filter window, you can select multiple check boxes to include several values in a single filter. For example, you can select both North America and Europe to show data for both regions.
What is the difference between a report filter and a page filter?
A report filter applies to the entire report, affecting all pages and all visuals. A page filter applies only to the current page. It will not affect visuals on other pages. Page filters are useful for restricting the data on a specific page without changing the context for the rest of the report.
How do I remove a filter?
To remove a filter, go to the Filter pane and locate the filter you want to remove. Click on the filter to open the filter window. Then, click on the Clear filter button. This button is usually a trash can icon or a clear button in the top right corner of the filter window.
Can I use DAX to create filters?
Yes, you can use DAX measures to create filters. DAX measures are calculated fields that can be used to filter visuals. For example, you can create a measure that calculates the total sales for the current year and then use this measure to filter a visual to show only the top products based on that measure.