Dashed (or dotted) grid lines?

I understand it’s possible to edit the width and color of gridlines with plotly using:

fig.update_xaxes(showgrid=True, gridwidth=1, gridcolor=‘LightPink’)

Is it however possible to edit the style of the grid lines? (e.g. dashed, dotted)

Hi @vl2376 unfortunately this is not possible at the moment. I’ve opened https://github.com/plotly/plotly.js/issues/4530 to record your request (could this be sponsored work by any chance?). If you absolutely need to make a figure with something which look like dashed/dotted grid lines, you add line shapes at ticks positions https://plot.ly/python/shapes/#vertical-and-horizontal-lines-positioned-relative-to-the-axes and style them (use the fact that you can give xref as x and yref as paper, and vice-versa, to draw infinite lines).

1 Like

Hi @Emmanuelle ; this osunds like a fix indeed. I hope styled lines will be available soon.

did this ever get implemented?