Adding Title and Subtitle

Learn how to set the title and subtitle in Altair.

A chart’s title is a brief text that provides context and summarizes the purpose or main idea of the chart. The title is typically placed at the top of the chart. We use concise and clear charts to help the audience understand what the chart is about and what insights it conveys.

A subtitle is a brief descriptive text that provides additional information about the main idea of a chart or other visual display of information. We can place the subtitle below the chart title.

How to configure a title in Altair

To configure a title in Altair, we can use the title parameter in the property() method. Here is the sample dataset to build the example below.

Get hands-on with 1200+ tech skills courses.