Bundled OpenSCAD Libraries — PrintPal Docs

Bundled OpenSCAD Libraries — PrintPal Docs

The browser-based AI CAD Modeler ships with two popular OpenSCAD libraries pre-installed: BOSL2 (Belfry OpenSCAD Library 2) and MCAD . They're lazy-loaded the first time you reference them — no manual setup, no install. This page documents what's bundled, how the loader works, and the license terms we honor for each library.

Just write use <…> or include <…> as you would in desktop OpenSCAD:

The same works for any MCAD file:

OpenSCAD compiled to WebAssembly has no host filesystem to read library files from, so use <BOSL2/std.scad> would normally silently fail. To make libraries work in the browser:

NopSCADlib, Round-Anything, dotscad/threads, and your own private libraries aren't bundled by default. Two workarounds: (1) paste the helper modules you need at the top of your file (the AI agent does this automatically for hardware), or (2) open the project in desktop OpenSCAD where the OS filesystem is available. If there's a library you'd like us to bundle, let us know .

BOSL2 is the de-facto standard library for OpenSCAD: hardware (screws/nuts/washers), gears, threads, splines, attachables, masks for fillets and chamfers, and a richer math toolkit. The AI agent will reach for BOSL2 idioms by default when generating mechanical parts.

MCAD is the older, OpenSCAD-team-maintained library of common mechanical parts: gears, motors (NEMA mounts), bearings, screws, teardrop holes, regular shapes, units, materials, and many more. It's smaller and less actively maintained than BOSL2, but the modules are well-tested and useful as drop-in primitives.

MCAD is distributed under the GNU Lesser General Public License, version 2.1. You can read the full license text here . In summary, the LGPL allows commercial use of MCAD as long as:

Models you design with MCAD modules are your work, not derivative works of MCAD. You can use them commercially with no restrictions. The LGPL only constrains what we (PrintPal) can do with the MCAD source — not what you can do with your OpenSCAD output.

Bundled libraries are vendored at build time. We update them periodically — the snapshot date is recorded inside each bundle.json :

If BOSL2 or MCAD ships a release with a bug fix or new module you need, drop us a line and we'll refresh the bundle. The whole vendoring pipeline is one Python script (~20 lines) so the turnaround is fast.

Recommended articles