This article is a GPT-5 translation and may contain errors. If anything is unclear, please refer to the original Chinese version.
orjson claims to be the fastest Python JSON library in the world. According to its README, its dumps can be up to 10x faster than the standard library json, and loads about 2x faster.
However let’s build a very simple, Chinese character only test case to reveal how orjson (v3.11.3) actually behaves in terms of performance and memory usage. Firstly for dumps: