For json parsing, the strongest matches are bytedance/sonic (Sonic is a high-performance Go library that provides JIT-accelerated), miloyip/rapidjson (RapidJSON is a high-performance C++ library that provides both) and jimhigson/oboe.js (This library is a specialized tool for streaming JSON). tencent/rapidjson and alibaba/fastjson round out the shortlist. Each is ranked by relevance to your query, popularity and recent activity.
Find the best JSON parser libraries for your project. Compare top-rated GitHub repositories by performance and activity to pick the right one.
Sonic is a high-performance Go JSON serialization library that provides tools for encoding and decoding native data structures. It functions as a JIT-accelerated encoder, a JSON AST parser, a stream processor, and a lazy decoder. The project utilizes just-in-time machine code generation to optimize the encoding of large data schemas and employs a JIT assembler to maximize serialization and deserialization speeds. It features a precompiled schema warmup process to prevent latency spikes during initial execution and leverages SIMD hardware instructions for accelerated parsing. The library cove
Sonic is a high-performance Go library that provides JIT-accelerated parsing, streaming support, and robust JSON manipulation, making it a comprehensive tool for efficient data processing.
RapidJSON is a high-performance C++ library used for parsing and generating JSON data. It provides both document object model and stream-based interfaces to transform JSON strings into structured data and vice versa. The library includes a JSON schema validator to verify that documents conform to predefined rules and a Unicode transcoder for converting strings between UTF-8, UTF-16, and UTF-32 encodings. It also supports relaxed parsing for non-standard JSON containing comments or trailing commas. Additional capabilities cover JSON pointer navigation for locating specific values and string s
RapidJSON is a high-performance C++ library that provides both DOM and SAX-style streaming interfaces, full schema validation, and robust serialization capabilities, making it a comprehensive tool for JSON processing.
oboe.js is a streaming JSON parser and HTTP stream client designed for incremental data processing. It allows applications to act upon individual JSON objects as they arrive from a network request or readable stream before the entire download completes. The library functions as a JSON stream transformer, enabling the modification, filtering, and mapping of nodes on the fly. It features path-based node selection to trigger callbacks when specific patterns are matched and can terminate a network connection early once required data is found to save bandwidth. To handle datasets larger than avai
This library is a specialized tool for streaming JSON parsing and on-the-fly transformation, making it a strong choice for high-performance processing of large datasets even though it lacks built-in schema validation.
RapidJSON is a header-only C++ library designed for high-performance parsing, generation, and manipulation of JSON data. It functions as a dual-mode engine, providing both an in-memory document object model for tree-based manipulation and a stream-based interface for event-driven processing. The library is built to minimize memory footprint and maximize execution speed, making it suitable for resource-constrained environments. The library distinguishes itself through advanced memory management and optimization techniques, including in-situ parsing that modifies input buffers directly to elimi
RapidJSON is a high-performance, header-only C++ library that provides both DOM and stream-based parsing, along with robust support for schema validation and efficient data manipulation.
Fastjson is a Java data binding framework and serialization library designed to convert objects to JSON strings and parse JSON data into typed objects. It functions as a JSON parser and stream processor capable of transforming JSON strings into data structures. The project emphasizes high performance JSON processing and memory management, specifically through the use of a pipeline to stream oversized JSON objects and texts to prevent memory exhaustion. It provides capabilities for JSON data serialization and deserialization workflows, including custom JSON data mapping and the ability to def
Fastjson is a high-performance Java library that provides robust JSON parsing, streaming, and data binding capabilities, making it a comprehensive tool for JSON manipulation and serialization.
gjson is a Go JSON parser designed for schema-less reading and value extraction. It allows for the retrieval of specific data from JSON documents using dot-notation paths without requiring the definition of predefined Go structs. The library provides tools for path-based querying, including the use of wildcards and index-based queries to locate data within objects and arrays. It also functions as a JSON lines processor, treating multi-line documents as arrays to iterate and query individual entries. Additional capabilities include converting JSON values into native Go types such as strings,
This library provides high-performance, zero-copy JSON parsing and path-based data extraction, making it a specialized tool for efficient JSON manipulation in Go even though it focuses on schema-less access rather than schema validation.
Ajv is a high-performance data validation framework that compiles JSON schemas into optimized, standalone JavaScript functions. By transforming declarative schema definitions into executable code, it eliminates runtime interpretation overhead and provides a secure, efficient way to enforce data integrity across both browser and server environments. The library distinguishes itself through its focus on performance and type safety. It employs advanced compilation techniques, including abstract syntax tree optimization and function caching, to ensure rapid validation. Beyond standard checks, it
Ajv is a high-performance JSON schema validation library that compiles schemas into optimized code, making it a flagship tool for ensuring data integrity and type-safe validation in JavaScript environments.
Jackson is a Java data binding framework and multi-format data serializer used to translate data structures into native language objects. It functions as a JSON data binding library and a streaming parser that reads and writes data as discrete tokens to process large datasets with minimal memory. The project distinguishes itself through a bytecode serialization accelerator that replaces standard reflection with generated bytecode to increase data binding speed. It employs a module-based extensibility model to support a wide range of formats beyond JSON, including XML, YAML, CSV, TOML, and bin
Jackson is a comprehensive, high-performance Java library that provides robust streaming parsing, schema validation, and type-safe data binding, making it a flagship tool for JSON processing.
yyjson is a high-performance C library for parsing, serializing, and manipulating JSON data structures. It functions as a memory-efficient data tool that utilizes custom memory pools and contiguous block allocation to minimize fragmentation and overhead. The project distinguishes itself as a SIMD JSON processor, using hardware-accelerated vector instructions for rapid string validation and parsing. It provides a toolkit for querying, modifying, and patching nested JSON objects and arrays through pointer-based access and path expressions. The library covers a broad range of data manipulation
This is a high-performance C library that provides fast parsing, serialization, and in-place manipulation of JSON data, meeting all the core requirements for a robust JSON processing tool.
This is a Rust serialization library for converting data structures to and from JSON strings and byte streams. It is built as a framework within the Serde ecosystem, providing both a strongly typed parser for compile-time safety and a recursive value tree for manipulating JSON data without a predefined schema. The project supports both typed and untyped processing. It can map JSON data into specific Rust types for schema conformity or parse input into a flexible, schemaless representation. It also includes macro-based utilities for the dynamic construction of JSON objects.
This library provides high-performance, type-safe serialization and parsing for Rust, offering both schema-based validation and flexible, schemaless manipulation of JSON data.
Newtonsoft.Json is a data processing utility for the .NET ecosystem designed to facilitate the transformation and exchange of information. It functions as a serialization library and object mapping framework, enabling the conversion of complex application objects into formatted JSON strings and the reconstruction of structured objects from raw JSON data. The library distinguishes itself through a flexible architecture that supports both strongly-typed class mapping and a dynamic object model for schema-less data manipulation. It employs reflection-based metadata mapping to automate property a
This is a comprehensive, high-performance JSON serialization and processing library for .NET that supports streaming, schema-less manipulation, and strongly-typed object mapping.
msgspec is a high-performance data modeling, serialization, and schema validation toolkit for Python. It serves as a type-safe serialization framework that integrates schema enforcement and data parsing into a single pass, functioning as both a data serialization library and a schema validation system based on standard Python type annotations. The project distinguishes itself through high-performance structural primitives, including compilation-based routine generation and zero-copy buffer parsing. It optimizes memory usage via garbage collection-aware layouts and reduces processing overhead
This library provides high-performance JSON parsing, schema validation, and type-safe serialization for Python, directly addressing all the core requirements for efficient data manipulation.
gojq is a JSON query engine and transformation tool implemented in Go. It serves as a Go language port of the jq command, providing a library for embedding JSON and YAML manipulation capabilities directly into Go applications. The tool functions as an arbitrary-precision JSON processor, performing mathematical operations on large integers to prevent precision loss or numeric overflow during data transformations. Its broader capabilities include filtering and reshaping structured data using a specialized query language, converting between YAML and JSON formats, and formatting date and time st
This library provides a robust engine for querying and transforming JSON data within Go applications, offering the core manipulation and processing capabilities required for complex data workflows.
simdjson is a high-performance, header-only C++ library designed for parsing, querying, and serializing JSON data with minimal memory overhead. It functions as a hardware-aware data processing engine that leverages vector instructions to achieve gigabyte-per-second parsing speeds. By detecting host processor capabilities at runtime, the library automatically selects the most efficient instruction sets to accelerate structural analysis and validation. The library distinguishes itself through a focus on extreme efficiency and resource management. It utilizes memory mapping and padded buffer ali
This is a high-performance C++ library for parsing and querying JSON that excels at speed and efficiency, though it lacks built-in schema validation features.
This library is a high-performance JSON processing tool for Java designed to handle data serialization and deserialization with minimal resource consumption. It provides a framework for transforming complex object graphs into JSON strings and mapping raw input directly to typed class properties. The library distinguishes itself by utilizing compile-time code generation and reflection-free mapping to eliminate expensive runtime overhead. By employing iterator-based stream parsing and zero-allocation buffer management, it processes large or deeply nested data structures while reducing garbage c
This library is a high-performance JSON processing tool for Java that provides efficient parsing, serialization, and streaming capabilities, making it a direct fit for the requested category.
cJSON is a lightweight library for parsing, creating, and modifying JSON data structures within C applications. It provides a comprehensive set of utilities for transforming raw text into navigable objects, manipulating data fields within collections, and serializing complex structures into formatted or unformatted strings. The library is designed for memory-sensitive and resource-constrained environments, utilizing manual memory management and type-tagged union structures to maintain a minimal footprint. It employs recursive descent parsing and in-place string manipulation to process data ef
This is a lightweight C library that provides core JSON parsing, creation, and serialization capabilities, making it a suitable tool for resource-constrained environments despite lacking built-in schema validation.
SwiftyJSON is a Swift JSON parsing library and data wrapper designed to simplify the reading and manipulation of JSON structures. It provides a toolkit for converting raw JSON strings into structured formats without requiring manual type casting or optional chaining for every value. The library focuses on simplifying nested data extraction through subscript-based value access and recursive data resolution. It ensures optional-safe value retrieval by returning default empty values instead of crashing when encountering missing keys or out-of-bounds array indices. The project includes capabilit
SwiftyJSON is a dedicated library for parsing and manipulating JSON in Swift, offering a type-safe and convenient way to handle nested data structures, though it lacks built-in schema validation and streaming support.
jsmn is a lightweight JSON parser library written in C. It provides zero-copy tokenization and incremental parsing designed for use in embedded systems and memory-constrained environments. The library identifies structural JSON elements by providing offsets into the original string rather than allocating new memory for data. It uses a single-pass scanning method and requires static-buffer allocation, meaning the caller provides the memory for tokens to avoid dynamic allocation during the parsing process. The parser supports incremental streaming, allowing it to process JSON data in chunks fr
This is a high-performance, zero-copy JSON parser designed for memory-constrained environments, though it focuses on tokenization rather than full schema validation or type-safe serialization.
Superjson is a lossless JSON serialization library and data transcoder. It converts complex JavaScript and TypeScript data types into strings and metadata to ensure that type identity is preserved during data transfer. The library preserves non-native types such as Dates, Maps, and Sets by splitting values into a JSON-compatible payload and a separate map of type-specific metadata. It utilizes a registry-based mapping system that allows for the definition of custom type handlers to manage third-party data types during serialization and deserialization. This utility supports cross-process dat
This library provides high-performance, type-safe serialization and transformation for complex JavaScript data types, making it a specialized tool for handling JSON-like data structures that require type preservation.
HandyJSON is a Swift JSON serialization library and data mapper. It functions as an object mapper that converts JSON data into typed Swift models and transforms Swift objects back into JSON strings for storage or transmission. The library uses reflection to automatically map JSON keys to object properties and supports custom mapping metadata to resolve naming differences between APIs and code. It provides capabilities for extracting values from deep nested paths within a JSON structure and supports the transformation of complex types such as dates and URLs. The framework handles both the des
HandyJSON is a Swift-based library that provides robust JSON serialization, deserialization, and object mapping capabilities, making it a direct fit for developers needing to integrate JSON data into typed models.
SBJson is an Objective-C JSON parser and generator designed for the parsing and generation of JSON data. It functions as a strict JSON validator, enforcing rigid grammar rules to ensure input data adheres to formal specifications. The project features an incremental JSON stream parser that processes UTF8 data in chunks to extract documents without loading the entire payload into memory. It also serves as a JSON data serializer that transforms native data objects into formatted strings using deterministic key sorting. The system manages data serialization workflows and implements security mea
SBJson is a specialized Objective-C library that provides high-performance incremental parsing, strict schema validation, and data serialization, making it a direct fit for JSON processing tasks in that ecosystem.
This library is a header-only C++ framework designed for the serialization, parsing, and manipulation of structured data. It provides a recursive variant data model that represents arbitrary structures as native types, allowing developers to navigate, modify, and patch hierarchical data using standard pointer paths and declarative update patterns. The project distinguishes itself through its template-based architecture, which enables type-safe data structures and custom type mapping at compile time. It offers a unified interface for binary format abstraction, supporting multiple compact repre
This header-only C++ library provides robust tools for parsing, serializing, and manipulating JSON data with a focus on type-safe integration and standard-compliant data modification.
Yup is a JavaScript schema validation library used to define data shapes and validate runtime values. It functions as an object schema validator and a data coercion engine, allowing developers to transform raw input values into desired types before performing validation checks. The library is distinguished by its support for dynamic schema validation, where rules can be adjusted at runtime based on sibling field values or external context. It also enables recursive data structuring for polymorphic fields and provides a system for extracting static TypeScript interfaces from runtime schema def
Yup is a robust schema validation and data transformation library that provides the core functionality for defining and enforcing data shapes, though it focuses more on validation logic than on high-performance raw JSON parsing or streaming.
JsonCpp is a C++ library for parsing, manipulating, and generating JSON data. It functions as a data interchange tool that provides a JSON parser to convert formatted text into structured data and a JSON serializer to transform internal data structures back into valid JSON strings. The library features the ability to preserve non-standard JSON comments during the deserialization and serialization process, which supports the management of human-readable configuration files. The project implements a tree-based internal representation for programmatic data access and uses a builder-based config
JsonCpp is a C++ library that provides robust parsing, serialization, and manipulation of JSON data, making it a direct fit for developers needing to handle JSON within their applications.
Gson is a Java library designed for the serialization and deserialization of objects into structured text formats. It functions as a reflection-based data mapper, inspecting class structures at runtime to automatically convert memory-resident objects into data representations and reconstruct them back into typed language objects. The library distinguishes itself through a modular type-adapter pattern that allows for custom conversion rules for complex or nested structures. It also provides robust support for production environments by generating build-time metadata and configuration rules, wh
Gson is a mature Java library that provides robust serialization, deserialization, and type-safe data mapping, making it a standard tool for handling JSON within the Java ecosystem.
jsonparser is a Go library for parsing, extracting, and modifying JSON data by key path without requiring predefined structs or type schemas. It uses a deterministic state machine to parse JSON directly from byte slices, enabling zero-copy traversal and lazy typed value extraction. The library provides key-path-based navigation to retrieve raw bytes and typed values from nested JSON structures, supporting extraction of strings, integers, floats, and booleans. It also enables in-place value modification and deletion at specified key paths, as well as iteration over arrays and objects using cal
This library provides high-performance, zero-copy JSON parsing and manipulation in Go, though it focuses on schema-free extraction rather than schema validation or type-safe serialization.
Valibot is a modular, type-safe schema library for validating and parsing structural data in TypeScript environments.
Valibot is a modular, type-safe library designed for schema validation and data transformation in TypeScript, making it a strong fit for developers needing to verify and parse structured data at runtime.
This is a JavaScript library for parsing and serializing JSON data, with a particular focus on handling objects that contain circular references. It provides a standard JSON parser that reads text and reconstructs JavaScript values without using the eval function, guarding against code injection, alongside a standard serializer that converts objects into JSON strings for data interchange. The library distinguishes itself by offering specialized encoding and decoding for cyclical object graphs. It can serialize objects with circular references by replacing repeated object paths with JSONPath s
This library provides fundamental JSON parsing and serialization capabilities, though it lacks modern features like schema validation and high-performance streaming support.
Moshi is a JSON serialization library and parser for Kotlin and Java. It functions as a reflectionless JSON encoder that converts typed objects to JSON strings and parses JSON data back into language objects. The library distinguishes itself through compile-time adapter generation, which removes the performance overhead associated with runtime reflection. It also provides a polymorphic JSON mapper that uses type identifiers to resolve and instantiate specific subclasses of a common base type. The framework supports custom adapter definitions for specialized type conversion, including nullabi
Moshi is a high-performance, reflectionless JSON serialization and parsing library for Kotlin and Java that provides type-safe mapping and streaming support, making it a direct fit for your development environment.
orjson is a high-performance Python library for serializing and deserializing JSON data. It functions as both a JSON parsing library and a serialization engine, converting data between native Python objects and UTF-8 encoded bytes. The project provides specialized support for converting complex Python data structures, including dataclasses, datetime objects, and NumPy arrays and scalars, into JSON format. It also allows for the insertion of pre-serialized JSON blobs into documents to maintain processing speed. The library includes capabilities for memory-efficient deserialization through key
This is a high-performance JSON serialization and deserialization library for Python that excels at parsing and converting complex data structures, though it lacks built-in schema validation features.
Zod is a TypeScript-first schema declaration and validation library designed to ensure end-to-end data integrity. It functions as a runtime type guard, allowing developers to define complex data structures through a declarative, chainable syntax. By using these schema definitions, the library automatically derives static TypeScript types, eliminating the need for manual type duplication and ensuring that runtime data matches expected application contracts. The library distinguishes itself through functional schema composition, which enables the creation of hierarchical structures by nesting a
Zod is a robust schema declaration and validation library that excels at runtime type safety and data transformation, making it a highly effective tool for managing JSON-like data structures in TypeScript environments.
Pydantic is a data validation and serialization library that enforces schema constraints and performs type conversion on complex data structures. It utilizes standard Python type annotations to define data models, allowing developers to establish structured schemas that automatically enforce business rules and constraints without the need for custom domain-specific languages. The library distinguishes itself by transforming high-level model definitions into optimized code during initialization to minimize runtime overhead. It supports recursive validation for nested data structures and employ
Pydantic is a robust library for data validation and type-safe serialization that uses Python type hints to enforce schemas, making it a standard tool for processing JSON-like data structures in Python applications.
https://github.com/json-c/json-c is the official code repository for json-c. See the wiki for release tarballs for download. API docs at http://json-c.github.io/json-c/
This is a C-based library for parsing and manipulating JSON data that provides the core functionality required for high-performance JSON handling in low-level environments.
🗄️ single header json parser for C and C++
This is a lightweight, single-header C/C++ library that provides high-performance parsing and serialization for JSON data, fitting the core requirements for a processing tool despite lacking built-in schema validation.
This library is a PHP-based serialization framework designed to convert complex object graphs into structured formats such as JSON, XML, YAML, and CSV, and to reconstruct those objects from serialized data. It functions as a data transformation tool that maps object properties to array structures, facilitating both application state persistence and the exchange of data between systems. The framework distinguishes itself through a two-stage pipeline that normalizes objects into intermediate structures before encoding them into specific formats. It supports advanced mapping requirements, includ
This component provides robust serialization and deserialization capabilities for PHP objects, making it a suitable tool for handling JSON data structures within a development environment.
Dataclasses-json is a library designed to facilitate the bidirectional conversion between Python data classes and JSON formats. It serves as a serialization tool that populates structured objects from raw data and transforms object instances into JSON strings, utilizing Python type hints to automate the mapping process. The library distinguishes itself by providing mechanisms for schema validation and runtime type coercion, ensuring that incoming data adheres to predefined model structures. It supports complex data requirements through recursive object traversal, which allows for the processi
This library provides a straightforward way to serialize and deserialize Python dataclasses to JSON, offering a type-safe approach that fits the category even if it lacks advanced features like streaming or schema validation.
A C++11 library for parsing and serializing JSON to and from a DOM container in memory.
This C++ library provides efficient parsing and serialization of JSON data into memory-resident DOM structures, fitting the core requirements for a JSON processing tool.
JSONKit is an Objective-C library used for parsing, serializing, and manipulating JSON data. It functions as a JSON parser that converts text into native data structures and a serializer that transforms native objects into formatted JSON text. The library includes a gzip compression wrapper that compresses serialized JSON payloads to reduce network transfer sizes and automatically detects and decompresses gzip buffers before decoding. The toolset provides capabilities for JSON parsing and serialization, supporting customizable indentation, character escaping, and flexible comment handling.
This is a high-performance Objective-C library for parsing and serializing JSON data, providing the core functionality required for JSON manipulation within that specific programming environment.
Fast, convenient JSON serialization and parsing in C++
This C++ library provides high-performance parsing and type-safe serialization for JSON, making it a strong choice for developers needing efficient data manipulation within their applications.
JSON-java is a Java library for parsing and generating JSON text and mapping it to Java objects and collections. It functions as a serialization framework for converting class instances and data structures into standardized JSON strings. The project includes a JSON pointer implementation for retrieving specific values from documents using string or URI fragment representations. It also provides a converter for translating data structures between JSON and XML, as well as a translator for transforming data between JSON and web formats such as HTTP headers, cookies, and comma-delimited lists. T
This is a Java library for parsing, generating, and mapping JSON data that provides essential serialization and transformation capabilities, making it a direct fit for your development needs.
VBA-JSON is a library designed for parsing and serializing JSON data within Visual Basic for Applications environments. It functions as an office automation data library, enabling legacy Microsoft Office applications to process structured data and interact with modern web services. The tool converts raw JSON text into native objects and collections, allowing developers to access and manipulate data using standard indexing and iteration methods. It also performs the reverse operation, transforming native language structures into JSON-compliant strings for exchange with external systems. By ha
This library provides the necessary functionality to parse and serialize JSON within the VBA environment, serving as a specialized tool for handling structured data in legacy Microsoft Office applications.
| Repository | Stars | Language | License | Last push |
|---|---|---|---|---|
| bytedance/sonic | 9.5K | Go | Apache-2.0 | |
| miloyip/rapidjson | 15.1K | C++ | NOASSERTION | |
| jimhigson/oboe.js | 4.8K | JavaScript | NOASSERTION | |
| tencent/rapidjson | 15K | C++ | other | |
| alibaba/fastjson | 25.6K | Java | Apache-2.0 | |
| tidwall/gjson | 15.5K | Go | MIT | |
| ajv-validator/ajv | 14.7K | TypeScript | MIT | |
| fasterxml/jackson | 9.7K | — | — | |
| ibireme/yyjson | 3.8K | C | MIT | |
| serde-rs/json | 5.6K | Rust | Apache-2.0 |