MongoDB.Bson 3.4.2

MongoDB C# Driver

You can get the latest stable release from the official Nuget.org feed or from our github releases page.

Getting Started

Untyped Documents

using MongoDB.Bson;
using MongoDB.Driver;
var client = new MongoClient("mongodb://localhost:27017");
var database = client.GetDatabase("foo");
var collection = database.GetCollection<BsonDocument>("bar");

await collection.InsertOneAsync(new BsonDocument("Name", "Jack"));

var list = await collection.Find(new BsonDocument("Name", "Jack"))
    .ToListAsync();

foreach(var document in list)
{
    Console.WriteLine(document["Name"]);
}

Typed Documents

using MongoDB.Bson;
using MongoDB.Driver;
public class Person
{
    public ObjectId Id { get; set; }
    public string Name { get; set; }
}
var client = new MongoClient("mongodb://localhost:27017");
var database = client.GetDatabase("foo");
var collection = database.GetCollection<Person>("bar");

await collection.InsertOneAsync(new Person { Name = "Jack" });

var list = await collection.Find(x => x.Name == "Jack")
    .ToListAsync();

foreach(var person in list)
{
    Console.WriteLine(person.Name);
}

Documentation

Questions/Bug Reports

If you’ve identified a security vulnerability in a driver or any other MongoDB project, please report it according to the instructions here.

Contributing

Please see our guidelines for contributing to the driver.

Thank you to everyone who has contributed to this project.

Showing the top 20 packages that depend on MongoDB.Bson.

Packages Downloads
MongoDB.Driver.Core
Core Component of the Official MongoDB .NET Driver.
29
MongoDB.Driver
Official .NET driver for MongoDB.
28
MongoDB.Driver
Official .NET driver for MongoDB.
21
MongoDB.Driver
Official .NET driver for MongoDB.
20

https://github.com/mongodb/mongo-csharp-driver/releases/tag/v3.4.2

Version Downloads Last updated
3.5.2 3 12/14/2025
3.5.1 4 11/21/2025
3.5.0 7 09/15/2025
3.4.3 9 09/05/2025
3.4.2 11 07/30/2025
3.4.1 11 07/30/2025
3.4.0 16 05/07/2025
3.3.0 15 04/04/2025
3.2.1 18 03/06/2025
3.2.0 19 03/06/2025
3.1.0 17 03/06/2025
3.0.0 18 03/06/2025
2.30.0 18 03/01/2025
2.29.0 19 03/01/2025
2.28.0 19 03/01/2025
2.27.0 19 03/01/2025
2.26.0 17 03/01/2025
2.25.0 18 05/02/2024
2.24.0 21 03/27/2024
2.23.2 20 03/27/2024
2.23.1 19 03/27/2024
2.23.0 21 03/27/2024
2.22.0 21 03/27/2024
2.21.0 20 03/27/2024
2.20.0 22 03/27/2024
2.19.2 20 03/27/2024
2.19.1 33 02/28/2024
2.19.0 20 03/27/2024
2.18.0 21 03/27/2024
2.17.1 19 03/27/2024
2.17.0 20 03/27/2024
2.16.1 21 03/27/2024
2.16.0 20 03/27/2024
2.15.1 21 03/27/2024
2.15.0 20 03/27/2024
2.14.1 19 03/27/2024
2.14.0 21 03/27/2024
2.14.0-beta1 20 03/27/2024
2.13.3 21 03/27/2024
2.13.2 20 03/27/2024
2.13.1 20 03/27/2024
2.13.0 22 03/27/2024
2.13.0-beta1 20 03/27/2024
2.12.5 21 03/27/2024
2.12.4 21 03/27/2024
2.12.3 20 03/27/2024
2.12.2 21 03/27/2024
2.12.1 21 03/27/2024
2.12.0 21 03/27/2024
2.12.0-beta1 21 03/27/2024
2.11.6 21 03/27/2024
2.11.5 20 03/27/2024
2.11.4 20 03/27/2024
2.11.3 21 03/27/2024
2.11.2 19 03/27/2024
2.11.1 21 03/27/2024
2.11.0 21 03/27/2024
2.11.0-beta2 20 03/27/2024
2.11.0-beta1 20 03/27/2024
2.10.4 21 03/27/2024
2.10.3 21 03/27/2024
2.10.2 21 03/27/2024
2.10.1 21 03/27/2024
2.10.0 21 03/27/2024
2.10.0-beta1 21 03/27/2024
2.9.3 19 03/27/2024
2.9.2 20 03/27/2024
2.9.1 18 05/02/2024
2.9.0 20 03/27/2024
2.9.0-beta2 20 03/27/2024
2.9.0-beta1 19 03/27/2024
2.8.1 20 03/27/2024
2.8.0 20 03/27/2024
2.7.3 21 03/27/2024
2.7.2 20 03/27/2024
2.7.1 20 03/27/2024
2.7.0 20 03/27/2024
2.7.0-beta0001 21 03/27/2024
2.6.1 20 03/27/2024
2.6.0 20 03/27/2024
2.5.1 20 03/27/2024
2.5.0 21 03/27/2024
2.4.4 20 03/27/2024
2.4.3 20 03/27/2024
2.4.2 20 03/27/2024
2.4.1 20 03/27/2024
2.4.0 20 03/27/2024
2.4.0-beta1 21 03/27/2024
2.3.0 20 03/27/2024
2.3.0-rc1 20 03/27/2024
2.3.0-beta1 21 03/27/2024
2.2.4 20 03/27/2024
2.2.3 21 03/27/2024
2.2.2 21 03/27/2024
2.2.1 21 03/27/2024
2.2.0 21 03/27/2024
2.2.0-rc0 20 03/27/2024
2.1.1 20 03/27/2024
2.1.0 20 03/27/2024
2.1.0-rc1 21 03/27/2024
2.1.0-rc0 21 03/27/2024
2.0.2 21 03/27/2024
2.0.1 21 03/27/2024
2.0.0 20 03/27/2024
2.0.0-rc0 21 03/27/2024
2.0.0-beta4 20 03/27/2024
2.0.0-beta3 19 03/27/2024
2.0.0-beta2 21 03/27/2024
2.0.0-beta1 21 03/27/2024