Plotter.add_title(title, font_size=18, color=None, font=None, shadow=False)

Add text to the top center of the plot.

This is merely a convenience method that calls add_text with position='upper_edge'.


The text to add the rendering.

font_sizefloat, optional

Sets the size of the title font. Defaults to 16 or the value of the global theme if set.

colorstr or 3 item list, optional,

Either a string, rgb list, or hex color string. Defaults to white or the value of the global theme if set. For example:

  • color='white'

  • color='w'

  • color=[1, 1, 1]

  • color='#FFFFFF'

fontstr, optional

Font name may be 'courier', 'times', or 'arial'.

shadowbool, optional

Adds a black shadow to the text. Defaults to False.


Text actor added to plot.


>>> import pyvista
>>> pl = pyvista.Plotter()
>>> pl.background_color = 'grey'
>>> actor = pl.add_title('Plot Title', font='courier', color='k', 
...                      font_size=40)