What Is a GLB File? Modern 3D Model Format
GLB Files: The Short Answer
A GLB file is a binary container format for 3D scenes and models, defined by the Khronos Group as part of the glTF 2.0 specification. The name stands for GL Transmission Format Binary — and that word 'binary' is the key distinction from its sibling format, GLTF. Where a .gltf file is a human-readable JSON text file that references external assets (textures, geometry buffers, animation data) stored in separate files, a .glb file bundles everything — the JSON descriptor, binary geometry buffers, and embedded textures — into a single self-contained package. That single-file design is why GLB has become the preferred delivery format for 3D content on the web, in AR applications, and across game engines. To put a size in perspective: a mid-complexity product model with PBR textures might weigh around 4–8 MB as a GLB, whereas the equivalent OBJ + MTL + PNG bundle could easily sprawl across a dozen files totaling 15 MB or more, with no guarantee every file arrives intact. Khronos published the glTF 2.0 specification in June 2017, and browser and engine support followed quickly. Today, GLB is natively supported in Windows 11's 3D Viewer, Apple's Quick Look on iOS and macOS, Google's model-viewer web component, Babylon.js, Three.js, Unity, Unreal Engine, Blender, and dozens of other tools. It has effectively become the JPEG of 3D — not perfect for every workflow, but universally readable.
How a GLB File Is Structured Internally
Understanding the internal layout of a GLB file helps explain both its strengths and its occasional quirks when converting to other formats. Every GLB starts with a 12-byte header containing three fields: a magic number (the ASCII bytes 0x46546C67, which spells 'glTF'), a version number (currently 2), and the total file length in bytes. After the header come one or more chunks. Chunk 0 is always a JSON chunk. It holds the scene graph — nodes, meshes, materials, cameras, animations, and skins — all described in glTF's JSON schema. This is the 'blueprint' of the 3D scene. Chunk 1, when present, is a binary buffer chunk. It stores the raw geometry data: vertex positions, normals, UV coordinates, bone weights, and animation keyframe values, all packed as tightly as possible into a binary blob. Textures can be embedded here too, stored as PNG or JPEG data within the binary chunk, referenced by the JSON via buffer views and accessors. This architecture has a practical consequence: you can open a GLB in a hex editor and read the JSON chunk directly starting at byte 20, which is occasionally useful for debugging. More practically, it means a well-formed GLB is always self-contained. If someone sends you a GLB file and it opens correctly, you know all the data is present — no missing texture files, no broken relative paths. One limitation worth noting: GLB only supports a single binary buffer chunk in the current spec. Complex scenes with many textures can therefore result in a single large contiguous blob, which is less efficient to stream progressively than formats designed specifically for streaming, like 3D Tiles.
GLB vs. GLTF vs. Other 3D Formats
The 3D file format landscape is crowded, and GLB occupies a specific niche. Here is how it compares to the formats you are most likely to encounter. **GLTF (.gltf):** Same specification, text-based. Use GLTF when you need to inspect or hand-edit the scene descriptor, or when your pipeline processes textures and geometry separately. Use GLB when you need a single portable file. **FBX (.fbx):** Autodesk's proprietary format, dominant in game production pipelines. FBX handles complex rigs, blend shapes, and multi-take animation data extremely well, and most DCC tools (Maya, 3ds Max, Cinema 4D) export it reliably. Its downside is that it is a closed binary format with no public specification, which causes subtle compatibility issues between software versions. GLB is the open alternative, though its animation support, while solid, is less battle-tested for very complex character rigs. **OBJ (.obj):** The oldest widely-used format, dating to the early 1990s. OBJ stores only static geometry and basic materials; it has no animation support, no PBR material model, and no scene hierarchy. It is still useful for simple mesh exchange but is increasingly being replaced by GLB for web delivery. **USD / USDZ (.usdz):** Apple's preferred AR format on iOS and macOS, based on Pixar's Universal Scene Description. USDZ is essentially a ZIP archive containing USD scene files and textures. It is excellent for Apple's ecosystem but less universally supported than GLB outside of it. Many AR workflows maintain both a GLB (for Android/web) and a USDZ (for iOS). **STL (.stl):** Used almost exclusively for 3D printing. Stores only surface geometry as triangles, no color, no materials, no animation. Not a competitor to GLB for rendering purposes. For web-based 3D, product configurators, e-commerce AR previews, and WebXR experiences, GLB is generally the best starting point.
Where GLB Files Are Actually Used
GLB's design makes it practical in several specific contexts, each with its own requirements. **E-commerce product visualization:** Shopify supports GLB files natively in its 3D/AR product media feature. A merchant uploads a GLB, and Shopify serves it via model-viewer on desktop and triggers AR Quick Look (converting to USDZ on the fly for iOS) on mobile. The recommended spec is under 15 MB, ideally under 4 MB for fast mobile load times, with textures no larger than 2048×2048 pixels. **WebXR and browser-based 3D:** Three.js's GLTFLoader and Babylon.js's SceneLoader both treat GLB as a first-class format. Loading a GLB into a Three.js scene is four lines of code. The format's support for PBR materials (metalness/roughness workflow) means lighting responds realistically without custom shaders. **Game engines:** Unity imports GLB via its GLTF Fast or KTX2 packages. Unreal Engine 5 added native GLB import in its datasmith pipeline. Godot 4 uses GLTF/GLB as its primary scene interchange format — Godot's own .tscn scenes can be exported as GLB for use in other tools. **Digital twins and industrial visualization:** Platforms like Autodesk Tandem and Bentley iTwin use GLB as one of their delivery formats for building and infrastructure models. A building floor plan converted from IFC to GLB can be rendered in a browser without any plugin. **Augmented reality apps:** Both Apple's Reality Composer and Google's Scene Viewer on Android accept GLB. When a user taps an AR link on an Android device, Chrome can launch Scene Viewer with a GLB URL directly. One area where GLB is less suitable: high-fidelity film VFX pipelines, where USD, Alembic, and OpenEXR dominate due to their richer support for subdivision surfaces, volumes, and multi-layer compositing data.
Converting To and From GLB with CocoConvert
CocoConvert handles the most common GLB conversion paths directly in the browser, without requiring you to install Blender, install a Python script, or sign up for a desktop application. **Converting GLTF to GLB:** Upload your .gltf file along with its associated .bin and texture files (you can select multiple files at once in the upload dialog). CocoConvert packages them into a single .glb, embedding the binary buffer and textures. This is the most reliable conversion path and preserves materials, animations, and scene hierarchy. **Converting OBJ to GLB:** Upload the .obj and its .mtl file together. CocoConvert reads the material definitions and attempts to map them to glTF's PBR material model. Standard diffuse colors and textures convert cleanly. Specular-heavy materials from older OBJ files may not translate perfectly to the metalness/roughness model — you may see shinier or flatter surfaces than expected, and manual adjustment in Blender (using the Principled BSDF shader) often gives better results for production assets. **Converting FBX to GLB:** This path works for many files but has known limitations. Complex character rigs with blend shapes, multi-layer animations, or proprietary Autodesk extensions may not convert fully. If your FBX contains multiple animation takes, CocoConvert currently exports only the default take. For production-grade character animation conversion, Blender's FBX importer followed by a manual GLB export gives you more control over which animations are included and how the rig is baked. **Converting GLB to other formats:** CocoConvert can export GLB to OBJ (geometry and basic materials only, no animation), STL (geometry only, for 3D printing), and GLTF (unpacked text format). GLB-to-FBX conversion is not currently supported — this is a genuinely hard problem because the two formats have different material models and animation systems, and no automated converter handles it perfectly. For any conversion, keep your source files organized: name textures clearly, avoid spaces in filenames, and check that your source model's geometry is clean (no non-manifold edges, no zero-area faces) before converting.
Optimizing GLB Files for Web Performance
A GLB file that looks great in Blender's viewport can be unusably slow in a browser if it hasn't been optimized for delivery. There are three main levers: geometry complexity, texture compression, and file size. **Geometry:** For a typical product model intended for e-commerce, aim for under 100,000 triangles. A coffee mug does not need 500,000 polygons. Use Blender's Decimate modifier (Mesh > Modifiers > Add Modifier > Decimate) to reduce polygon count while preserving silhouette. A Collapse ratio of 0.1–0.3 often reduces triangles by 70–90% with minimal visible quality loss at typical viewing distances. **Texture compression:** Standard GLB files embed textures as JPEG or PNG. For web delivery, KTX2 textures with Basis Universal compression (the EXT_texture_basisu glTF extension) can reduce texture memory on the GPU by 4–8x compared to uncompressed PNG, and they decompress directly on the GPU rather than requiring CPU-side decompression. The glTF-transform CLI tool (npm install -g @gltf-transform/cli) can apply this compression: run gltf-transform etc input.glb output.glb --slots "baseColor,normal" to compress the most impactful texture channels. **Draco mesh compression:** The KHR_draco_mesh_compression extension applies Google's Draco algorithm to geometry buffers, typically reducing geometry data by 60–80%. Three.js and Babylon.js both support Draco-compressed GLB with their respective Draco decoder libraries. glTF-transform applies it via: gltf-transform draco input.glb output.glb. **Practical target sizes:** Under 1 MB for a simple product model, 1–5 MB for a detailed product with multiple texture maps, 5–15 MB for architectural or complex scene content. Above 15 MB, consider lazy-loading, level-of-detail switching, or splitting the scene into multiple GLB files loaded on demand. CocoConvert applies basic texture resizing and mesh simplification during conversion, but for production-level optimization, the glTF-transform CLI or the Gestaltor desktop editor give you finer control.
Opening and Inspecting GLB Files Without Special Software
One of GLB's practical advantages is that you rarely need to install anything to open one. **Windows 11:** Double-clicking a .glb file opens it in the built-in 3D Viewer application. You can rotate, zoom, and inspect the model. Windows 10 also supports this via the 3D Viewer app from the Microsoft Store. **macOS and iOS:** GLB files can be previewed via Quick Look — select the file in Finder and press Space. On iOS, tapping a GLB file in Files or Safari will trigger Quick Look with an option to place the model in AR using the device's LiDAR or ARKit capabilities. **Online viewers:** The official glTF sample viewer at https://sandbox.babylonjs.com and Don McCurdy's https://gltf.report are both free browser-based tools. gltf.report is particularly useful because it shows you polygon count, texture sizes, draw calls, and flags potential issues with your file — all without uploading to any server (it processes files locally in the browser). **VS Code:** The Cesium glTF Tools extension for Visual Studio Code lets you preview GLB files and inspect the raw JSON scene descriptor side by side. This is useful when debugging conversion artifacts — you can see exactly which material properties were set and compare them against what you expected. **Blender:** File > Import > glTF 2.0 (.glb/.gltf) imports GLB directly. Blender 3.3 and later handle the import reliably for most files. Once imported, you can inspect materials in the Shader Editor, check the scene hierarchy in the Outliner, and re-export with different settings. If a GLB file fails to open in any of these tools, the most common causes are: the file was truncated during download, the JSON chunk contains non-standard extensions that the viewer doesn't recognize, or the textures inside are in a format (like KTX2) that the viewer doesn't support. In those cases, gltf.report's validation output usually points to the specific problem.