Bring Drag & Drop to Dash with Dashboard Engine. 💫 Learn how at our next webinar!

Changing cursor on go.Scatter plot on hover over point only

Hi, I’m trying to change the mouse cursor from crosshair to pointer when I hover over the “points” on my scatter plot.
Changing CSS changes the cursor over the entire plot, but I want to change the cursor to pointer only when it hovers over the points and stay as default crosshair everywhere else in the plot.

What’s the best way to achieve this?

Minimum example to test:

import pandas as pd
import plotly.graph_objects as go
import dash
import dash_bootstrap_components as dbc
import dash_core_components as dcc
import dash_html_components as html

df = pd.DataFrame(
        "x": range(5),
        "y": range(5),
        "url": [""]*5

fig = go.Figure(

# Setup the Dash App
external_stylesheets = [dbc.themes.BOOTSTRAP]
app = dash.Dash(__name__, external_stylesheets=external_stylesheets)

# Server
server = app.server

app.layout = html.Div([

if __name__ == "__main__":

Change the cursor to pointer only when the mouse hovers over the points in the plot. I plan to make the points clickable with URLs, hence changing the cursor to indicate those points are clickable will help the user experience.