Displaying a 3D scatter with a lot of data crashes

Is there an efficient way to do this? I’m having crashes with even 1000 data points. I noticed that using different colors for data points (i.e. zcolor) makes the figure 10x heavier upon saving.

I would like to be able to rotate the image, like it is in plotly, rather than a static scatter. I thought my computer would be able to display heavy plots:
32 × 13th Gen Intel(R) Core™ i9-13900K
128 GB RAM
Can you say what would be a reasonable number of points to handle?
Would Makie be better at this?

using Plots
n = 500
scatter3d(eachcol(rand(n,3))..., zcolor=rand(n))

Thank you.

Did you try the plotlyjs() backend?

Also, many people use Makie.jl nowadays for interactive 3D visualization:

It works OK in the MS Edge browser and with n = 10_000 points in my small Win11 laptop:

Device name	XPS13-7390
Processor	Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz   1.50 GHz
Installed RAM	32.0 GB

However, it takes more than 30 s to render the plot, and until then we need to click Wait every time a window pops up saying This page isn't responding.

I could not make plotlyjs to work. I’m new to Makie, but I tried using WGLMakie, using the following code (Not sure if this is the best way to do it):

using JSServe
using WGLMakie

Page(exportable=true, offline=true)
n = 5000
x = rand(n)
y = rand(n)
z = rand(n)
c = rand(n)
f = Figure()
a = WGLMakie.scatter(x, y, z, color=c)
WGLMakie.save("test1.html", a.figure)

Overall, it seems that the HTML file does not scale with n in either size or time to render, unlike Plotly, which seems to scale linearly with n, so in that sense it’s great.
The only thing I find missing is that in Plotly, by default I can click on labels in the legend to hide the corresponding series. Is it easily done in Makie as well?