How to remove the Trace0 and Trace 1 boxes when hovering over pie charts in subplot?

In the screenshot below, how do I remove the trace0 (and trace 1 for the 2nd pie chart) from showing up and only show the first hover box? I found a few things online, but they aren’t helping. I’ve attached my code below. Any help would be appreciated!

    fig = make_subplots(
        rows=1, cols=2,
        specs=[[{"type": "pie"}, {"type": "pie"}]])
    
    fig.add_trace(go.Pie(labels=proj_userRoles["Role"].tolist(),values=proj_userRoles["Count"].tolist(),title=project+" User Roles",legendgroup="1"),
                  row=1, col=1)

    fig.add_trace(go.Pie(labels=proj_sessions["Session"].tolist() ,values=proj_sessions["Count"].tolist(),title=project+" Datatypes",legendgroup="2"),
                  row=1, col=2)
    fig.show()

Hi @Ashmistry Welcome to the forums.

Try to change the hovertemplate:

hovertemplate = " whatever you need <extra></extra>"
1 Like

So I had found that exact thing with the extra, I just don’t know what to put in “whatever you need”. I want to keep the labels and values parameters. I’ve tried but no success.

Just paste this " whatever you need <extra></extra>" in the hover template