Skip to content
masterclass Buddy

Plotly · Function

px.bar

Create vertical or horizontal bar charts with Plotly Express. Map data columns to x and y, then control colors, grouping, labels, text, patterns, and facets.

Last updated

Since
5.5

Syntax

plotly.express.bar(data_frame=None, x=None, y=None, color=None, orientation=None, barmode=None, text=None, text_auto=False, hover_data=None, facet_row=None, facet_col=None, labels=None, height=None, ...)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • plotly.express
  • px.histogram
  • plotly.graph_objects
  • go.Bar
  • barmode
  • orientation
  • facet_row
  • facet_col

Source: Horizontal bar charts in Python. Checked 2026-11-03.