For AI agents: a documentation index is available at https://www.mongodb.com/docs/llms.txt — markdown versions of all pages are available by appending .md to any URL path.
Docs Menu

Authentication Mechanisms

In this guide, you can learn how to authenticate to MongoDB by using the authentication mechanisms available in MongoDB Server. Authentication mechanisms are processes that the driver and server use to confirm client identity and establish a secure connection.

Tip

Connecting to MongoDB

To learn how to establish a connection to your MongoDB deployment, see the Create a MongoClient guide.

The authentication mechanisms in the table vary by MongoDB deployment type. The following table summarizes the compatibility of each authentication mechanism with different MongoDB editions. You can learn more about the different authentication mechanisms in the corresponding guides.

Authentication Mechanism
Atlas
Enterprise Advanced
Community

Yes

Yes

Yes

Yes

Yes

Yes

Yes

Yes

No

No

Yes

No