3MF Format: The Modern Standard for 3D Printing Files
3MF (3D Manufacturing Format) is an open XML-based file format developed by the 3MF Consortium — a group that includes Microsoft, Autodesk, HP, Stratasys, Ultimaker, Dassault Systèmes, and others. Launched in 2015, 3MF was designed from the ground up to replace STL as the primary format for additive manufacturing, combining geometry, materials, colors, print settings, and support structures into a single portable container.
Unlike STL, which encodes nothing but flat triangles, 3MF carries everything a slicer needs to reproduce a print exactly: the model geometry, the material assignments, the color map, the print quality settings, and even vendor-specific slicing instructions. It is now the default format in Windows 3D Builder, natively supported in PrusaSlicer, Cura, Bambu Studio, Orca Slicer, and most modern 3D printing workflows.
The 3MF Container Structure
A 3MF file is a ZIP archive with the .3mf extension. Inside, it follows the Open Packaging Conventions (OPC) standard — the same container format used by modern Office documents (.docx, .xlsx). This means you can open a .3mf file with any ZIP tool:
model.3mf (ZIP archive)
├── [Content_Types].xml ← MIME type declarations
├── _rels/
│ └── .rels ← Relationship declarations
└── 3D/
├── 3dmodel.model ← Primary geometry + materials
├── _rels/
│ └── 3dmodel.model.rels ← Texture relationships
└── Textures/
├── basecolor.png
└── metallic.png
This container approach means textures, thumbnails, and print configuration files are bundled alongside the geometry — a significant advantage over STL, which must rely on separately managed texture files.
The Core 3MF Specification
The geometry is defined in 3dmodel.model, an XML file:
<?xml version="1.0" encoding="UTF-8"?>
<model unit="millimeter" xml:lang="en-US"
xmlns="http://schemas.microsoft.com/3dmanufacturing/core/2015/02"
xmlns:m="http://schemas.microsoft.com/3dmanufacturing/material/2015/02">
<metadata name="Title">Customized Bracket</metadata>
<metadata name="Designer">Design Team</metadata>
<metadata name="CreationDate">2024-03-15</metadata>
<resources>
<basematerials id="1">
<base name="PLA White" displaycolor="#FFFFFF"/>
<base name="PLA Red" displaycolor="#FF2000"/>
<base name="TPU Black" displaycolor="#1A1A1A"/>
</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="10" y="10" z="0"/>
<vertex x="0" y="10" z="0"/>
<vertex x="5" y="5" z="8"/>
</vertices>
<triangles>
<triangle v1="0" v2="1" v3="4" pid="1" p1="0" p2="0" p3="0"/>
<triangle v1="1" v2="2" v3="4" pid="1" p1="1" p2="1" p3="1"/>
<triangle v1="2" v2="3" v3="4" pid="1" p1="2" p2="2" p3="2"/>
<triangle v1="3" v2="0" v3="4" pid="1" p1="0" p2="0" p3="0"/>
<triangle v1="0" v2="3" v3="2"/>
<triangle v1="0" v2="2" v3="1"/>
</triangles>
</mesh>
</object>
</resources>
<build>
<item objectid="2" transform="1 0 0 0 1 0 0 0 1 0 0 0"/>
</build>
</model>
Key structural elements:
<basematerials> — defines a palette of materials/colors. Each <base> has a name and a display color in hex RGB. The pid and pindex attributes on triangles reference which palette entry applies to that triangle.
Per-triangle material — the pid, p1, p2, p3 attributes on <triangle> elements assign materials at the triangle level, or even interpolate between three different materials across a single triangle surface. This is the mechanism for color gradients and material blending at print boundaries.
<build> — the build list specifies which objects to print and their placement transform (a 4×3 affine matrix, row-major). Multiple items can be placed at different positions on the same build plate within a single 3MF file.
The Materials and Properties Extension
The core 3MF spec handles basic material assignments, but the Materials and Properties extension (namespace http://schemas.microsoft.com/3dmanufacturing/material/2015/02) adds:
- Texture 2D — UV-mapped color textures
- Color groups — vertex-level per-vertex color arrays
- Composite materials — mixtures of base materials (e.g., 60% PLA + 40% carbon fiber)
- Multi-properties — stacking multiple property layers on the same geometry
<m:texture2d id="5" path="/3D/Textures/basecolor.png"
contenttype="image/png"
tilestyleu="wrap" tilestylev="wrap"
filter="linear"/>
<m:texture2dgroup id="6" texid="5">
<m:tex2coord u="0.0" v="0.0"/>
<m:tex2coord u="1.0" v="0.0"/>
<m:tex2coord u="0.5" v="1.0"/>
</m:texture2dgroup>
The Beam Lattice Extension
For lightweight structural design, 3MF includes a Beam Lattice extension that encodes complex lattice structures efficiently:
<bl:beamlattice minlength="0.1" radius="0.5" clippingmode="inside"
xmlns:bl="http://schemas.microsoft.com/3dmanufacturing/beamlattice/2017/06">
<bl:beams>
<bl:beam v1="0" v2="1" r1="0.5" r2="0.5"/>
<bl:beam v1="1" v2="4" r1="0.5" r2="0.3"/>
<bl:beam v1="0" v2="3" r1="0.5" r2="0.5"/>
</bl:beams>
</bl:beamlattice>
This allows gyroid, Schwartz P, and other triply periodic minimal surface (TPMS) lattice structures to be encoded as beam graphs rather than dense triangulated meshes, reducing file size by orders of magnitude for internal lattice-filled objects.
Print Ticket / Slice Extension
The Slice extension allows 3MF files to contain pre-sliced layer data:
<sl:slices xmlns:sl="http://schemas.microsoft.com/3dmanufacturing/slice/2015/07">
<sl:slicestack id="7" zbottom="0">
<sl:slice ztop="0.2">
<sl:vertices>
<sl:vertex x="5.0" y="5.0"/>
<sl:vertex x="15.0" y="5.0"/>
<sl:vertex x="15.0" y="15.0"/>
<sl:vertex x="5.0" y="15.0"/>
</sl:vertices>
<sl:polygon startv="0">
<sl:segment v2="1"/>
<sl:segment v2="2"/>
<sl:segment v2="3"/>
<sl:segment v2="0"/>
</sl:polygon>
</sl:slice>
</sl:slicestack>
</sl:slices>
This is particularly valuable for firmware-level transmission: instead of sending a full 3D model to an embedded printer controller, the slicer running on a host PC can pre-compute all layers and send the compact 2D slice data, reducing computational load on the printer itself.
3MF in Python
import zipfile
import xml.etree.ElementTree as ET
NS = {'core': 'http://schemas.microsoft.com/3dmanufacturing/core/2015/02'}
def read_3mf(filepath):
with zipfile.ZipFile(filepath, 'r') as zf:
with zf.open('3D/3dmodel.model') as f:
tree = ET.parse(f)
root = tree.getroot()
vertices = []
for v in root.findall('.//core:vertices/core:vertex', NS):
vertices.append((
float(v.get('x')),
float(v.get('y')),
float(v.get('z'))
))
triangles = []
for t in root.findall('.//core:triangles/core:triangle', NS):
triangles.append((
int(t.get('v1')),
int(t.get('v2')),
int(t.get('v3'))
))
print(f"Vertices: {len(vertices)}")
print(f"Triangles: {len(triangles)}")
# Extract metadata
for meta in root.findall('.//core:metadata', NS):
print(f"{meta.get('name')}: {meta.text}")
return vertices, triangles
vertices, tris = read_3mf('model.3mf')
Converting Between 3MF and Other Formats
PrusaSlicer CLI:
prusa-slicer --export-3mf --output model.3mf model.stl
prusa-slicer --export-stl --output model.stl model.3mf
Blender Python (via the 3MF add-on):
import bpy
bpy.ops.import_mesh.threemf(filepath='/path/to/model.3mf')
bpy.ops.export_mesh.threemf(filepath='/path/to/output.3mf')
FreeCAD has native 3MF import/export through the Mesh workbench.
3MF vs STL vs AMF
| Feature | 3MF | STL (binary) | AMF |
|---|---|---|---|
| Open standard | ✅ 3MF Consortium | ✅ de facto | ✅ ISO/ASTM 52915 |
| Container format | ✅ ZIP/OPC | ❌ Single file | ❌ Single XML |
| Multi-material | ✅ Yes | ❌ No | ✅ Yes |
| Textures | ✅ Bundled in ZIP | ❌ No | ✅ Base64 in XML |
| Lattice structures | ✅ Beam lattice ext | ❌ No | ❌ No |
| Pre-sliced layers | ✅ Slice extension | ❌ No | ❌ No |
| Print settings | ✅ Yes | ❌ No | ❌ No |
| Curved surfaces | ❌ Flat only | ❌ Flat only | ✅ Yes |
| Slicer support | ✅ Universal modern | ✅ Universal | ⚠️ Limited |
| File size | Small-Medium | Small | Small-Large |
Why 3MF Won the Adoption Battle
Several factors drove 3MF to become the de facto modern 3D printing standard:
-
Microsoft integration — 3MF is the native format for Windows 3D Builder and the Windows 10/11 print pipeline, giving it immediate exposure to millions of users
-
Industry consortium — major printer manufacturers (HP, Stratasys, Desktop Metal) and software vendors (Autodesk, Dassault) committed to 3MF from launch
-
Practical architecture — the ZIP container bundles everything a slicer needs, and the extension model (materials, lattices, slices) allows the format to grow without breaking backward compatibility
-
Slicer adoption — PrusaSlicer, Cura, Bambu Studio, Orca Slicer, and IdeaMaker all use 3MF as their native project format, replacing their proprietary formats
Conclusion
3MF has succeeded where AMF struggled: it delivers a technically complete replacement for STL with broad industry support, practical tooling, and a clear extension roadmap. By packaging geometry, materials, colors, textures, and print settings into a single ZIP container, 3MF eliminates the fragmentation that plagued STL-based workflows. Understanding 3MF's structure — the OPC container, the XML geometry model, the materials extension, and the beam lattice and slice extensions — prepares you for working at the cutting edge of additive manufacturing software, whether you are building a slicer, designing printable multi-material assemblies, or architecting a cloud-based 3D printing pipeline.
Related conversions
Frequent conversions across the catalogue: