Label Aliases wot working, plotly 5.14.1

Thank you very much for your work! Label Aliases is what I have been waiting for a long time. But, unfortunately, the example from the documentation does not work for me.

import as px
import pandas as pd

df =
df = df[['Sat', 'Sun'])].groupby(by='day', as_index=False).sum(numeric_only=True)

fig =, x="day", y="total_bill")
fig.update_xaxes(labelalias=dict(Sat="Saturday", Sun="Sunday"))

Plotly version is 5.14.1. Help me please.

HI @Morozov welcome to the forums.

Can’t reproduce this with plotly 5.14.1, python 3.10.4 on linux.

Which OS do you use?

Hi @AIMPED. I am using MacOS. Python 3.11.3.

Exactly. When I run the code on linux everything works as it should. It turns out that the problem is only on macos.

1 Like

Thanks for the feedback, seems to be a bug then. I added the bug_reporter tag to the topic.

You could open an issue on github:


Thank you @AIMPED

Hi @Morozov
Let me know if you need help opening an issue in our repo.

Thank you @adamschroeder . I have already created an issue. Label aliases does not work at MacOS · Issue #4173 · plotly/ · GitHub


hi @Morozov

We tested it in MacOS, but it worked. Could it be related to the Python IDE that you’re using? Are you using VS Code?

Thanks a lot! The problem was in vscode. This is what helped:

import as pio
pio.renderers.default = 'notebook'