6.5 GB/s JSON Parsing in Mojo — Beating Rust and C++ on Apple Silicon


mojo-json parses JSON at 6.5 GB/s on Apple Silicon — 52% faster than the fastest C++ and Rust parsers.

We benchmarked 6 JSON parsers across 3 languages on an M3 Ultra. mojo-json wins all 3 files.

The Numbers

LibraryLanguagetwitter.jsoncanada.jsoncitm_catalog.json
mojo-jsonMojo6,574 MB/s5,673 MB/s6,337 MB/s
simdjsonC++4,313 MB/s3,898 MB/s5,970 MB/s
sonic-rsRust1,650 MB/s1,144 MB/s2,855 MB/s
simd-jsonRust1,019 MB/s494 MB/s1,269 MB/s
orjsonPython794 MB/s405 MB/s817 MB/s
serde-jsonRust353 MB/s535 MB/s806 MB/s

10 iterations each, 5 warmup. Apple M3 Ultra, macOS Sequoia 15.2.

What the Benchmarks Test

These files are from nativejson-benchmark, the standard suite for JSON parser comparison:

FileSizeTests
twitter.json617 KBWeb API payloads, Unicode, nested objects
canada.json2.2 MBGeoJSON coordinates, heavy float parsing
citm_catalog.json1.7 MBDeeply nested structures, mixed types

How

mojo-json implements the simdjson algorithm in Mojo:

  • ARM NEON SIMD via C FFI for 64-byte vectorized chunk processing
  • Branchless classification with lookup tables
  • Prefix-XOR string tracking using carry-less multiply
  • Pure Mojo — no Python interpreter overhead

The result: simdjson-level performance in a language with Python’s syntax.

Try It

git clone https://github.com/atsentia/mojo-json
cd mojo-json/neon && ./build.sh
mojo run -I . benchmarks/bench_neon.mojo

Full benchmark methodology: docs/BENCHMARKS.md

Note: These results are from a single hardware configuration (M3 Ultra). Performance may vary on other systems — we’d welcome community benchmarks on different platforms.

Amund Tveit

AI Engineer & Advisor