JSON VS BSON Exactly Difference


 In this article, we learn MongoDB  JSON VS BSON  working.


It will good to cover my articles before this. It helps to learn more about MongoDB. In which I explained. Click here How can Manage Reference in MongoDB and  Replication in MongoDB.

Wha is BSON

The binary JSON and BSON is a binary serialized format which is used for storing the document and remote procedure called in MongoDB.

BSON is a PC information trade organize utilized for the most part as an information stockpiling and system move design in the MongoDB database. The BSON stands for Binary javascript object notation. BSON always binary formate <01010101 or 11111111. The MongoDB uses BSON to store the document.

BSON is the parallel encoding of JSON-like reports that MongoDB utilizes while putting away archives in accumulations. It includes bolster for information composes like Date and double that aren’t upheld in JSON.

It is a binary shape for speaking to basic information structures, acquainted exhibits (called object or records in MongoDB), and different information sorts of particular enthusiasm to MongoDB. Like BSON and JSON support embedded document in the array. The BSON also supported data types that are not part of JSON.

BSON support the following data types.
  1. Double: Eight byte is equal to 64 bit for floating point.
  2. int64: 8 byte is equal to 64 bit.
  3. int32: Four type 32 bits.
  4. Byte: One byte is equal to eight bits.
The Binary JSON 
  • Lightweight
  • Traversable
  • Efficient
  • Fast scalability
  • Data types

When uses our the network BSON keep the overhead extra header data to the minimum. the Data rep­res­ent­a­tion format, es­pe­cially when used over the net­work.


It helps in the role of primary data management for MongoDB.It design traversal easy to the network.BSON is de­signed to be tra­versed eas­ily.


It uses c data types make easy to encoding and decoding of data.

The MongoDB drivers send and receive data in BSON format. And however, the MongoDB even stores data as BSON Object. Since encoding data to BSON and decoding data from BSON can be performed very quickly and hence it is highly efficient also.


Practically speaking, you don’t need to know much about BSON when working with MongoDB, it simply tells us the document are stored internally.

{“name”: “USA”, “gender”: “not know”, “company”: “SEO”,}

you simply need to utilize the local kinds of your dialect and the provided composes of its driver while developing reports and they will be mapped into the fitting BSON compose by the driver.

Wha is JSON

We can manage data easily using JSON.Javascript object notation(JSON) open data interchange formate. The JSON used to pass data in the server and back. The JSON structure consists of array and object.

A collection of name/esteem value sets. In a different language, this is acknowledged as a question, record, struct, word reference, hash table.

An arranged rundown of qualities. In many languages, this is acknowledged as an exhibit, sequence, and list.

It is language independent. Use the convention of c  family language java javascript and Perl python also support the basic data types. It also supports the basic data types such as array string boolean value and hashes.

  • Lightweight and interchange formate
  • Easy for human read and write.easy for the machine to parse and generate
  • Text format that completely language independent

Jason data consists of <object> and <array>. The data in a document is the form of key and value pair. The data is separated by commas. The curly bracket {  } hold objects and Box bracket [] represent the array.

Here is an example of JSON formate.


I wish I could tell you that a great site of MongoDB.you just understands key element above post-MongoDB JSON VS BSON working.

BSON is intended to be effective in space, however at times isn’t substantially more proficient than JSON. At times BSON utilizes considerably more space than JSON.

The explanation behind this is one more of the BSON outline objectives: navigability. BSON includes some “additional” data to records, similar to the length of strings and subobjects. This makes traversal quicker.

BSON is likewise intended to be quick to encode and translate. For instance, numbers are put away as( 64 or 32) or float bit whole numbers, so they don’t should be parsed to and from content. This uses more space than JSON for little numbers, however, is substantially quicker to parse.

More conservativeness, BSON includes extra information composes inaccessible in JSON, prominently  Date information composes.

. More, detail about MongoDB BSON, please click here BSON AND JSON working. You also read my previous lecture. I hope you will understand this lecture. Thank you for reading this lecture. Hope you got the idea. please share it.

Previous articleMongoDB Replication working
Next articleAndroid 8.0 Oreo Top 10 Best advise
My name is Muhammad Zubair. I want to help you a lot of things that a blog provide. You feel free to ask the question anytime you might have! While most recently, he tends to share her wealth of knowledge and expertise on SEO, link building, inbound marketing,