MongoNetworkError: connection 3 to cluster0-shard-00-02-z0urk.mongodb.net:27017 closed MongoNetworkError: connection 3 to cluster0-shard-00-02-z0urk.mongodb.net:27017 closed mongoose mongoose

MongoNetworkError: connection 3 to cluster0-shard-00-02-z0urk.mongodb.net:27017 closed


I had same problem when i want to connect to https://cloud.mongodb.com "mongoDB Atlas"This problem happened to me because when I built project, my IP in this time store in security -> IP Whitelist.

You will only be able to connect to your cluster from the following list of IP Addresses in IP Whitelist.

I manage to solve this problem by using IP 0.0.0.0/0 this help me to connect from anywhere.

Would that help you?


from mongo-db

go to cluster

find security

check the IP, list

add the current ip or the global ip or bothyou can add any other ip for development

check step by step in the link below

good luck

https://intercom.help/mongodb-compass/en/articles/1898157-connection-3-to-cluster0-shard-00-00-a1b2c-mongodb-net-27017-closed