skillfed

streamlit-plotly-events

Plotly chart component for Streamlit that also allows for events to bubble back up to Streamlit.

streamlit-plotly-events v0.0.6 112.5K downloads/30d#12,369 on PyPI233
License unclear DORMANT released

What it is and what it does

Streamlit Plotly Events is a Streamlit custom component that bridges Plotly charts with Streamlit's event system. It wraps Plotly figures and exposes click, select (lasso), and hover events, returning a list of dictionaries containing point details (x, y, curve index, point index) that your Streamlit app can react to. This enables interactive workflows where users click or hover on chart elements and your app responds in real time.

The package is lightweight—it depends only on streamlit and plotly—and integrates seamlessly with Streamlit's component API. You pass a Plotly figure to the `plotly_events()` function, optionally configure which events to listen for via kwargs, and receive back the selected point data. The documentation notes that hover events are resource-intensive, suggesting they should be used selectively.

Use it for:

  • Build dashboards where clicking a data point filters or highlights related data elsewhere on the page.
  • Create exploratory data tools where hovering reveals detailed tooltips or triggers calculations.
  • Implement lasso-select workflows to let users select multiple points and export or analyze them.
  • Add drill-down interactivity to charts, where clicking a point opens a detail view or nested analysis.
  • Prototype interactive scientific or financial visualizations that respond to user selections in real time.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Captures click, select, and hover events from Plotly charts rendered in Streamlit, returning point details back to your app for interactive workflows.

Yes, with conditions. The package solves a real gap—native Streamlit lacks Plotly event capture—and has low install friction. However, maintenance is dormant (last release April 2021); compatibility with current streamlit and plotly versions is unverified, and the license is unclear. Install it for prototyping or internal tools, but evaluate compatibility and licensing before production use.

Install

streamlit-plotly-events on PyPI

pip

pip install streamlit-plotly-events

uv

uv add streamlit-plotly-events

poetry

poetry add streamlit-plotly-events

Installing streamlit-plotly-events

Before you install

Low friction: pure Python wheel with only streamlit and plotly as runtime dependencies. Maintenance is dormant—last release was 2021-04-26, though the repo remains unarchived and saw a commit as recently as 2024-07-16. No recent activity suggests compatibility issues may accumulate.

License in practice

License treatment is unclear—no SPDX identifier or raw license text is recorded. Before relying on this package in a commercial or copyleft context, verify the actual license from the repository.

Quickstart

pip install streamlit-plotly-events

import plotly.express as px
from streamlit_plotly_events import plotly_events

fig = px.line(x=[1], y=[1])
selected_points = plotly_events(fig)

Requires Python 3.6 or later and both streamlit and plotly to be installed.

Verify before relying

  • Compatibility with current versions of streamlit and plotly (last release 2021-04-26, no recent updates).
  • Whether hover_event is truly resource-intensive in practice and under what conditions.
  • Performance impact when handling large numbers of overlapping points or high-frequency events.

Package facts

License not declared (unclear)
Python support supports the current Python release (>=3.6)
Install friction low — pure-Python wheel
Runtime dependencies 2 — streamlit, plotly
Maintenance dormant — 1,936 days since the last release
Last repo commit
First released
Downloads 112,485/month — #12,369 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: streamlit_plotly_events-0.0.6-py3-none-any.whl

Tags

plotly chart events in streamlitstreamlit plotly interactivitycapture plotly click eventsstreamlit custom plotly componentplotly hover select eventsstreamlit chart interaction
streamlit-componentplotly-integrationinteractive-charts

More Graphics packages