Open files in VS Code and Cursor / 3D and imaging

View STL files in VS Code

Install the free 3D Model Viewer and click the .stl file. Drag to orbit, right-drag or Shift-drag to pan, and scroll to zoom. A panel lists vertices, triangles and size, and Measure (M) shows the distance between two points with its X, Y and Z parts. The same extension opens OBJ, PLY, 3MF, GLB and glTF.

Install in VS CodeMarketplace pageOpen VSX (Cursor, Windsurf, VSCodium)

Free, MIT license. Extension ID zovo.3d-model-viewer, version 0.1.5. Needs VS Code 1.90.0 or newer.

A gear STL with Measure on. Two red points on opposite sides of the gear are joined by a line labelled 51.36 units, and the status bar shows the delta in x, y and z
A gear STL with Measure on. Two red points on opposite sides of the gear are joined by a line labelled 51.36 units, and the status bar shows the delta in x, y and z.

Steps in VS Code

  1. Install 3D Model Viewer from the Marketplace, or press Ctrl+P (Cmd+P on macOS) and run ext install zovo.3d-model-viewer.
  2. Click a .stl, .obj, .ply, .3mf, .glb or .gltf file.
  3. Orbit, pan and zoom with the mouse. Press W for wireframe, N for normals, B for the bounding box.
  4. Press M and click two points to measure.
  5. Save a screenshot as PNG.

Steps in Cursor, Windsurf or VSCodium

  1. Open the Extensions view with Ctrl+Shift+X (Cmd+Shift+X on macOS).
  2. Search for zovo.3d-model-viewer and click Install. Cursor, Windsurf and VSCodium install from Open VSX, where it is published as zovo/3d-model-viewer.
  3. If your editor has no gallery, download the .vsix from the Open VSX page and run "Extensions: Install from VSIX...".
  4. Then use it the same way as in VS Code.

What 3D Model Viewer handles

What it does not do

Other options

Install counts and Open VSX status were checked on 8 November 2026. Descriptions in quotes are the extensions' own.

Questions

What unit are STL measurements in?

STL files carry no unit. The viewer shows raw coordinates, which are usually millimetres when the file came from a CAD tool for printing.

Can it open OBJ files with materials?

Yes, when the .mtl file sits next to the model.

Does it work offline?

Yes. It makes no network calls and has no telemetry.

More about 3D Model Viewer

Read the 3D Model Viewer page for every feature and setting, or the source code on GitHub.

Support this work

If this extension saves you time, you can support the work on GitHub Sponsors. Monthly tiers start at $5, and one-time tiers start at $15. Sponsorship is optional, and the tool works the same without it.