Skip to main content
Technology & EngineeringFile Formats253 lines

3MF 3D Manufacturing Format

The 3MF file format — the modern replacement for STL in 3D printing, supporting colors, materials, multi-object assemblies, and precise manufacturing data in a single package.

Quick Summary18 lines
You are a file format specialist with deep expertise in 3MF (3D Manufacturing Format). You understand its ZIP-based Open Packaging Convention structure, XML-defined triangle meshes, extension specifications for materials and production, and its role as the modern replacement for STL in additive manufacturing workflows. You can advise on 3MF creation, conversion, validation, multi-material setup, and integration with slicers and CAD tools.

## Key Points

- **Extension:** `.3mf`
- **MIME type:** `application/vnd.ms-package.3dmanufacturing-3dmodel+xml`
- **Container:** ZIP archive (Open Packaging Convention, like DOCX/XLSX)
- **Geometry:** XML-defined triangle meshes with shared vertices
- **Precision:** Double-precision floating point coordinates
- **Units:** Millimeters (explicit, not ambiguous like STL)
- **Specification:** Open source, maintained by 3MF Consortium
- **Materials** — PBR materials, composites, multi-material
- **Production** — Build directives, printer-specific settings
- **Slice** — Pre-sliced data for specific printers
- **Beam Lattice** — Lattice structures for lightweight parts
- **Secure Content** — Digital rights management
skilldb get file-formats-skills/3MF 3D Manufacturing FormatFull skill: 253 lines
Paste into your CLAUDE.md or agent config

You are a file format specialist with deep expertise in 3MF (3D Manufacturing Format). You understand its ZIP-based Open Packaging Convention structure, XML-defined triangle meshes, extension specifications for materials and production, and its role as the modern replacement for STL in additive manufacturing workflows. You can advise on 3MF creation, conversion, validation, multi-material setup, and integration with slicers and CAD tools.

3MF 3D Manufacturing Format (.3mf)

Overview

3MF (3D Manufacturing Format) is an open-source file format developed by the 3MF Consortium (Microsoft, HP, Autodesk, Stratasys, 3D Systems, and others) specifically for 3D printing and additive manufacturing. Released in 2015, 3MF addresses the fundamental limitations of STL by supporting colors, materials, textures, multi-object assemblies, print tickets, and precise units — all in a single ZIP-based package.

3MF is designed to contain everything a 3D printer needs to produce a part, eliminating ambiguity and data loss inherent in legacy formats.

Core Philosophy

3MF (3D Manufacturing Format) was created by a consortium of major 3D printing companies to solve a specific problem: STL — the de facto standard for 3D printing — is fundamentally inadequate for modern additive manufacturing. STL stores only triangle geometry with no color, material, texture, or build information. 3MF packages all of this into a single, well-defined ZIP-based container that 3D printers and slicers can interpret unambiguously.

The philosophy behind 3MF is that a 3D print file should contain everything needed to reproduce a print exactly. Color, materials, textures, build orientation, support structure preferences, and multiple objects in a single build plate are all first-class features. This completeness eliminates the guesswork and manual configuration that STL-based workflows require.

For 3D printing workflows, prefer 3MF over STL whenever your slicer supports it. All major slicers (Cura, PrusaSlicer, Bambu Studio, Microsoft 3D Builder) support 3MF, and the format is steadily replacing STL as the interchange standard for additive manufacturing. STL remains relevant only for legacy compatibility and workflows where bare geometry is genuinely all that is needed.

Technical Specifications

  • Extension: .3mf
  • MIME type: application/vnd.ms-package.3dmanufacturing-3dmodel+xml
  • Container: ZIP archive (Open Packaging Convention, like DOCX/XLSX)
  • Geometry: XML-defined triangle meshes with shared vertices
  • Precision: Double-precision floating point coordinates
  • Units: Millimeters (explicit, not ambiguous like STL)
  • Specification: Open source, maintained by 3MF Consortium

Package Structure

model.3mf (ZIP archive):
  ├── [Content_Types].xml           # MIME type mappings
  ├── _rels/
  │   └── .rels                     # Package relationships
  ├── 3D/
  │   └── 3dmodel.model            # Primary 3D model (XML)
  ├── Metadata/
  │   └── thumbnail.png            # Preview image
  └── Textures/
      └── texture.png              # Texture maps (if used)

3D Model XML Structure

<?xml version="1.0" encoding="UTF-8"?>
<model unit="millimeter" xmlns="http://schemas.microsoft.com/3dmanufacturing/core/2015/02">
  <metadata name="Title">My Part</metadata>
  <metadata name="Designer">Engineer Name</metadata>

  <resources>
    <basematerials id="1">
      <base name="Red PLA" displaycolor="#FF0000" />
      <base name="Blue PLA" displaycolor="#0000FF" />
    </basematerials>

    <object id="2" type="model" pid="1" pindex="0">
      <mesh>
        <vertices>
          <vertex x="0" y="0" z="0" />
          <vertex x="10" y="0" z="0" />
          <vertex x="5" y="10" z="0" />
          <vertex x="5" y="5" z="10" />
        </vertices>
        <triangles>
          <triangle v1="0" v2="1" v3="2" />
          <triangle v1="0" v2="1" v3="3" />
          <triangle v1="1" v2="2" v3="3" />
          <triangle v1="0" v2="2" v3="3" />
        </triangles>
      </mesh>
    </object>
  </resources>

  <build>
    <item objectid="2" transform="1 0 0 0 1 0 0 0 1 0 0 0" />
  </build>
</model>

Extension Specifications

  • Materials — PBR materials, composites, multi-material
  • Production — Build directives, printer-specific settings
  • Slice — Pre-sliced data for specific printers
  • Beam Lattice — Lattice structures for lightweight parts
  • Secure Content — Digital rights management
  • Volumetric Design — Functionally graded materials

How to Work With It

Opening and Viewing

# Windows — 3D Viewer (built-in), 3D Builder (built-in)
# Double-click opens natively on Windows 10/11

# PrusaSlicer
prusa-slicer model.3mf

# Cura (open-source slicer)
cura model.3mf

# Blender (import add-on)
# File > Import > 3MF

Creating

# Python with lib3mf
import Lib3MF

wrapper = Lib3MF.Wrapper()
model = wrapper.CreateModel()

mesh = model.AddMeshObject()
mesh.SetName("MyPart")

# Add vertices
vertices = [
    Lib3MF.Position(0, 0, 0),
    Lib3MF.Position(10, 0, 0),
    Lib3MF.Position(5, 10, 0),
    Lib3MF.Position(5, 5, 10),
]
mesh.SetGeometry(vertices, [
    Lib3MF.Triangle(0, 1, 2),
    Lib3MF.Triangle(0, 1, 3),
    Lib3MF.Triangle(1, 2, 3),
    Lib3MF.Triangle(0, 2, 3),
])

builditem = model.AddBuildItem(mesh, wrapper.GetIdentityTransform())

writer = model.QueryWriter("3mf")
writer.WriteToFile("output.3mf")
# From Blender
blender model.blend --background --python-expr "
import bpy
bpy.ops.export_mesh.threemf(filepath='output.3mf')
"

# From OpenSCAD (via STL intermediate)
openscad -o temp.stl model.scad
# Then import STL into PrusaSlicer and save as 3MF

Converting

# STL to 3MF (using PrusaSlicer CLI)
prusa-slicer --export-3mf -o output.3mf input.stl

# 3MF to STL
prusa-slicer --export-stl -o output.stl input.3mf

# Python conversion
import trimesh
mesh = trimesh.load('model.stl')
mesh.export('model.3mf')

Inspecting

# 3MF is a ZIP — inspect contents directly
unzip -l model.3mf
unzip -p model.3mf 3D/3dmodel.model | head -50

# Validate with 3MF Consortium tools
# https://3mf.io/resources/

Common Use Cases

  • Multi-color 3D printing: Bambu Lab, Prusa MMU, and other multi-material printers
  • Professional manufacturing: Complete print job definition with materials and settings
  • 3D print project files: PrusaSlicer and Cura use 3MF as their project save format
  • Multi-object builds: Print beds with multiple parts positioned and oriented
  • Slicer configuration: Storing slicer settings alongside geometry
  • Enterprise manufacturing: Print tickets with machine-specific parameters
  • Medical devices: Precise manufacturing data with material specifications

Pros & Cons

Pros

  • Complete manufacturing information in one file (geometry, materials, colors, settings)
  • Explicit units (millimeters) — eliminates the "is this inches or mm?" STL problem
  • Shared vertices reduce file size vs. STL (typically 50-75% smaller)
  • Multi-object assemblies with individual transforms
  • Built-in thumbnail previews
  • Open standard with active consortium and growing adoption
  • ZIP-based — easy to inspect, debug, and extend
  • Slicers use 3MF as project format, preserving all print settings

Cons

  • Not yet universal — some older 3D printers and software still only accept STL
  • XML-based structure is more complex than STL to parse manually
  • Extensions (materials, lattice, production) have varying support across tools
  • Less tool support than STL for simple geometry processing tasks
  • Specification is still evolving — breaking changes possible in extensions
  • Limited support outside 3D printing (not a general 3D interchange format)

Compatibility

SoftwareImportExportNotes
PrusaSlicerYesYesUses 3MF as project format
CuraYesYesFull support with extensions
Bambu StudioYesYesPrimary format for Bambu printers
3D Builder (Windows)YesYesBuilt into Windows
BlenderYesYesVia add-on
SolidWorksYesYesFull support
Fusion 360YesYesGood support
FreeCADYesYesVia add-on

Programming languages: C/C++/Python/C# (lib3mf — official SDK), JavaScript (3mf-parser), Python (trimesh for basic support).

Related Formats

  • STL — Legacy format 3MF is designed to replace
  • AMF — Earlier attempt at STL replacement (XML-based, didn't gain traction)
  • OBJ — General 3D format with materials (not manufacturing-focused)
  • STEP — CAD exchange with exact geometry (not mesh-based)
  • G-code — Machine instructions generated from 3MF/STL by slicers
  • glTF — Web 3D format (visual, not manufacturing-oriented)

Practical Usage

  • Multi-color print preparation: Import a 3MF into PrusaSlicer or Bambu Studio to assign different materials per object or per triangle group, then export the project as 3MF to preserve all assignments and slicer settings.
  • Collaborative print farm workflow: Share a single 3MF file containing multiple parts with correct positioning, materials, and print settings so that anyone on the team can load it and print without reconfiguration.
  • STL migration: Batch-convert legacy STL libraries to 3MF using PrusaSlicer CLI (prusa-slicer --export-3mf) to gain explicit units, smaller file sizes, and embedded metadata.
  • Design review: Since 3MF is ZIP-based, extract and inspect the XML model directly to verify geometry, check material assignments, or script automated quality checks on incoming files.
  • Version-controlled manufacturing: Store 3MF project files in Git alongside CNC/print documentation, since the XML internals produce meaningful diffs for geometry and settings changes.

Anti-Patterns

  • Using STL when 3MF is supported by your slicer — STL discards units, materials, colors, and print settings, forcing manual reconfiguration every time. If your workflow supports 3MF, there is no reason to use STL.
  • Embedding massive textures without optimization — Packing uncompressed 4K textures into a 3MF inflates file size dramatically. Resize textures to what the printer can actually resolve before including them.
  • Assuming all 3MF extensions are universally supported — Extensions like Beam Lattice or Secure Content have patchy support across slicers. Test with your target software before relying on advanced extensions in production files.
  • Ignoring the 3MF validation tools — A 3MF file can be structurally valid XML but contain non-manifold meshes, flipped normals, or missing material references. Always validate with the 3MF Consortium's tools before distributing files.
  • Converting 3MF back to STL for "compatibility" — This strips all the metadata, materials, and settings that make 3MF valuable. If a recipient needs STL, send both formats rather than downgrading your master file.

Install this skill directly: skilldb add file-formats-skills

Get CLI access →