Technologies
The same scenes, four ways.
Every page below covers the same two reference scenes: an animated cosine-palette plasma (three cosines a phase apart) and a lit, depth-tested, spinning cube. WebGL and WebGPU render them on the page; Three.js and vgpu print the code that would and say so, because neither is a dependency of this site. The maths never changes, so what you are comparing is purely the code you have to write around it — and the cube is the more honest half, because a full-screen effect exercises almost no plumbing.
colour = 0.5 + 0.5 · cos(time + uv.xyx + (0, 2, 4))
Which should you use?
There is no best one — there is a best one for a target. Answer three questions and see what falls out, along with the reasoning.
This is a rule of thumb, not a verdict — the scoring is a few dozen lines you can read in lib/chooser.ts. The one hard rule is compute: WebGL has no compute stage, so no amount of preference makes it — or anything drawing through it — the answer there.
Side by side
Of these eight numbers, six are counted rather than asserted: each is the length of the listing printed on that page, by the same rule as the line count in the listing’s own header, so the figures here cannot disagree with the code underneath them. The two carrying a tilde — WebGL’s cube and WebGPU’s cube — are estimates of a complete implementation, because those listings are excerpts and there is nothing printed to count. Either way the figure is the plumbing around the shader, not a quality score: fewer lines means more is being done for you, which is exactly what you want in one situation and exactly what you do not want in another. Of the two scenes the cube is the more honest: the plasma has no geometry, no camera and no depth buffer, so it barely exercises the differences at all.
WebGL
Open →Browser API · GLSL
The baseline. Everything on this site runs on it.
WebGPU
Open →Browser API · WGSL
The successor. Stricter, far more capable, and finally shipping.
Three.js
Open →Library · scene graph
A scene, not a pipeline. The default answer for most 3D on the web.
vgpu
Open →Library · WebGPU + WGSL
A small typed layer over WebGPU that also runs headless.
Not sure which to learn first? Start with WebGL — not because it is the future, but because everything else here is a reaction to it, and the ideas transfer. The labs are almost all built on it — the two that cannot be are marked, and say why — and the reading path takes it from there.