BSON Converter

Convert between MongoDB BSON and JSON

ObjectId Tools

What is BSON?

  • • Binary JSON format used by MongoDB
  • • Supports ObjectId, Date, Binary types
  • • More efficient storage than plain JSON
  • • Extended JSON format supports special types

BSON & MongoDB Extended JSON Guide

What is BSON?

BSON (Binary JSON) is a binary-encoded serialization of JSON-like documents. MongoDB uses BSON as its primary data storage and network transfer format. BSON supports additional data types not available in standard JSON.

Extended JSON Format

MongoDB Extended JSON is a string format for representing BSON documents. It allows you to work with BSON types in a human-readable JSON format:

ObjectId: {"$oid": "507f1f77bcf86cd799439011"}
Date: {"$date": "2024-01-01T00:00:00Z"}
Long: {"$numberLong": "9223372036854775807"}
Binary: {"$binary": {"base64": "...", "subType": "00"}}

ObjectId Structure

A MongoDB ObjectId is a 12-byte identifier consisting of:

TTTTTTTTMMMMMMPPPPCCCCCC
T (8 chars): Unix timestamp
M (6 chars): Machine identifier
P (4 chars): Process ID
C (6 chars): Counter

Related Tools

Developer Tools

Explore 80+ free online tools for developers. Base64, JSON, JWT, Regex, and more essentials in one place.

Quick Links

Developer Tools © 2025. All rights reserved.

Most tools run in the browser; tools that require network access only send data when you run them.

BSON/MongoDB Extended JSON Converter | Developer Tools