You can create a heat map in Power BI by converting a table visual to a matrix, then changing the fill color of the cells based on a numerical value. This turns a simple list of numbers into a visual grid where lighter colors indicate lower values and darker colors indicate higher values.

What You'll Need

  • A Power BI Desktop or Power BI Service account with access to the data source.
  • A dataset containing at least one categorical column and one numerical column.
  • Basic familiarity with the Power BI interface and field selection.

Step-by-Step

  1. Create the initial table. Open the report canvas in Power BI Desktop or the report view in the Power BI Service. Drag the table visual onto the canvas. In the Fields pane, select the categorical column you want to use for the rows (e.g., Product Category) and the numerical column you want to analyze (e.g., Sales Amount). The visual will display a standard table with rows and columns of data.
  2. Transform the table into a matrix. With the table visual selected, look for the Visualizations pane on the right side of the screen. Find the Matrix icon and click it. Power BI will automatically convert your table into a matrix visual. This matrix will have the selected categorical column as the row headers and the numerical column as the values in the cells.
  3. Adjust the matrix structure. The default matrix may show all the data as a single column or a very wide grid. To create a proper grid for a heat map, you usually need to add a second categorical column to the columns area of the Fields pane. For example, if your data is organized by Year, drag the Year field to the Columns well in the Fields pane. The matrix now has a row (e.g., Product Category), a column (e.g., Year), and a value (e.g., Sales Amount) for each intersection.
  4. Change the visual type to a table again. This is a specific trick in Power BI. While the matrix is still selected, go back to the Visualizations pane and click the Table icon again. This action converts the matrix back into a table, but it retains the matrix’s underlying structure of rows and columns.
  5. Activate the Heat Map. With the table visual selected, click the Heat Map icon in the Visualizations pane. Power BI will apply a color scale to the cells. The cells in the matrix will now be colored based on the magnitude of the numerical value they contain. Larger numbers will appear in darker or more intense colors, while smaller numbers will be lighter.
  6. Customize the color scale. By default, Power BI uses a sequential color scheme (like blue or green) that goes from light to dark. To change this, look for the Conditional formatting option. You can find this by clicking the paint roller icon (Format visual) and selecting Conditional formatting > Colors. In the pane that appears, you can change the color palette (e.g., to a diverging scale like orange and blue), set the minimum and maximum values for the scale, and adjust the number format of the cells.

Common Mistakes

One of the most common mistakes is trying to find a direct "Heat Map" option in the Visualizations pane without first converting a table or matrix. Power BI does not have a standalone heat map visual; it relies on this specific conversion method from a table or matrix. If you don't see a Heat Map icon, you haven't completed the previous steps correctly.

Another frequent issue is failing to set up the matrix correctly before converting it. If you don't have both rows and columns defined in your matrix (e.g., you only have rows and no columns), the table will remain a single column, and the heat map will not display a grid pattern. It is essential to have a two-dimensional structure (rows x columns) for a heat map to work properly.

Tips

Use a sequential color scale for data that has a natural order, such as sales figures, temperature, or population. A diverging color scale, which uses two contrasting colors (like red and blue) with a neutral color in the middle, is better suited for data that has a meaningful midpoint, such as profit or loss, where you want to highlight positive and negative values.

When setting the conditional formatting, ensure the "Show items with no value" option is enabled if you want to see empty cells represented in the color scale. If this option is off, empty cells will appear white or transparent, which can make the visual harder to read and compare against the rest of the grid.

Troubleshooting

If the heat map does not appear or shows only white cells, first check that you have a numerical value in the cells. If the field you selected contains text or dates, Power BI cannot apply a numerical color scale. Ensure the field in the Values well is a number.

If the colors are not changing, go to the Conditional formatting > Colors settings and ensure the "Field value" is selected as the basis for the formatting. Sometimes, the visual may default to formatting based on a measure or a different field if it detects that the current field is not numeric.

If the visual is too crowded, try reducing the number of rows or columns in your matrix. You can do this by adding a slicer to the report and selecting a specific subset of data, or by using a DAX measure to summarize the data before placing it in the visual. A less crowded grid will make the color gradients easier to interpret.

Frequently Asked Questions

Can I use a heat map with text data?

No, a Power BI heat map requires a numerical value to determine the color intensity. It cannot be used to visualize text or categorical data directly. You must have a number field to apply the color scale.

Does the Heat Map visual support tooltips?

Yes, the Heat Map visual supports tooltips. When you hover over a colored cell, Power BI will display the underlying data values for that specific cell, including the row and column headers and the numerical value.

How do I create a heat map that uses two different numerical fields for coloring?

Power BI’s built-in heat map functionality applies a single color scale based on one field. To use two different fields, you would need to create a custom visual from the AppSource or write a DAX measure that combines the fields into a single calculated value before placing it in the visual.

Can I save a custom color scheme for a heat map?

Yes, you can save custom color schemes. In the Conditional formatting > Colors pane, you can manually pick colors for the minimum and maximum values. These settings are saved with the report, so they will be applied whenever you open the file.

Is there a way to see the exact numerical value inside the colored cell?

By default, the color represents the value, and the value is shown in the tooltip. To show the value directly on the cell, you can add a text field to the visual. Click the Text icon in the Visualizations pane and drag the numerical field there. The text will appear on top of the color, though it may be harder to read if the colors are very dark.