Skip to content
Studio 3T - The professional GUI, IDE and client for MongoDB
  • Tools
    • Aggregation Editor
    • IntelliShell
    • Visual Query Builder
    • Export Wizard
    • Import Wizard
    • Query Code
    • SQL Query
    • Connect
    • Schema Explorer
    • Compare
    • SQL ⇔ MongoDB Migration
    • Data Masking
    • Task Scheduler
    • Reschema
    • AI Helper
    • Team Sharing
    • Performance Suite
    • More Tools and Features
  • Solutions
  • Resources
    • Knowledge Base
    • MongoDB Tutorials & Courses
    • Tool/Feature Documentation
    • Blog
    • Community
    • Testimonials
    • Whitepapers
    • Reports
  • Contact us
    • Contact
    • Sales Support
    • Feedback and Support
    • Careers
    • About Us
  • Store
    • Buy Now
    • Preferred Resellers
    • Team Pricing
  • Download
  • My 3T
search

Studio 3T® Knowledge Base

  • Documentation
  • Tutorials
  • Workshops
Take the fastest route to learning MongoDB. Cover the basics in two hours with MongoDB 101, no registration required.
Start the free course

How to Connect to MongoDB Atlas

Posted on: 24/09/2020 (last updated: 21/09/2023) by Kathryn Vargas

What is MongoDB Atlas?

MongoDB Atlas is MongoDB’s own fully-managed global cloud database-as-a-service, which can be run on Amazon Web Services (AWS), Google Cloud Platform, or Microsoft Azure.

In this post, we’ll show you how to connect to MongoDB Atlas, MongoDB’s fully-managed DBaaS, using Studio 3T.

Don’t have a MongoDB Atlas account? Here’s a tutorial on how to set up a free M0 cluster.

If you’re having issues connecting to MongoDB Atlas, we recommend our troubleshooting guide instead.

Prerequisites

  1. Get your first MongoDB Atlas cluster for free.
  2. Download the latest Studio 3T version on your Windows, Mac, or Linux machine.
What’s included in a free MongoDB Atlas cluster?

The free cluster includes:

  • 512 MB of storage
  • Shared RAM
  • Highly available replica sets, end-to-end encryption, automated patches, REST API
  • Max connections: 100
  • Network performance: Low
  • Max databases: 100
  • Max collections: 500

See MongoDB’s Cloud Provider page for a list of supported regions for your free tier cluster.

1. Get the connection string from MongoDB Atlas

Log in to your MongoDB Atlas account. This will take you to the overview of your cluster.

Click on Connect.

Click on Connect in the cluster overview

Choose Drivers under Connect to your application.

Choose Drivers under Connect to your application

Choose your driver and driver version. We use Java and Version 4.3 or later in this example, but the latest version of any driver should also generate a compatible connection string.

Choose the MongoDB driver and version

You don’t need to do anything for Step 2 because the driver is packaged with Studio 3T.

You don't need to install the driver because it's already packaged with Studio 3T

Copy the generated connection string. This is what you’ll need to paste in Studio 3T.

Copy the MongoDB Atlas connection string

2. Whitelist your IP address

If you have a dynamic IP address, it’s worth double-checking the MongoDB Atlas IP Access List.

Click on Network Access under the Security section on the left-hand sidebar. This will take you to the IP Access List.

Click on Add IP Address in the top-right corner.

Go to the IP Access List

On the Add IP Access List Entry dialog, click on Add current IP address.

Add current IP address in MongoDB Atlas

MongoDB automatically detects your current address. Click Confirm.

Are you connecting from another IP address, through a VPN, or getting errors? Troubleshoot MongoDB Atlas connection issues with our guide.

3. Connect to Studio 3T

Open Studio 3T and click on Connect in the top-left corner of the toolbar. This will open the Connection Manager.

Click on New Connection in the top-left corner.

Open the Connection Manager in Studio 3T

In the New Connection dialog, paste the connection string you copied from MongoDB Atlas.

Paste the MongoDB connection string

Replace the placeholders <username> and <password> with the actual username and password. Make sure to replace the brackets too, and click Next.

You’ll be prompted that ‘Your connection has been successfully auto-configured.’ Click OK.

On the New Connection dialog, Studio 3T will automatically extract the information and pre-populate the fields in the Server, Authentication, SSL, SSH tunnel, and Advanced tabs. It will also save the connection for later use. Name your connection.

Name the MongoDB Atlas connection

Click on Test Connection. A successful test will look like this:

Test the MongoDB Atlas connection

Click OK to close the dialog. On the New Connection dialog, click Save. On the Connection Manager dialog, click Connect.

If you’re getting a connection error, e.g. Prematurely reached end of stream, make sure your IP address has been whitelisted on MongoDB Atlas.

4. Import data in JSON, CSV, BSON/mongodump or SQL

If you have an empty cluster, you can easily import JSON, CSV, BSON/mongodump or SQL to MongoDB with Studio 3T’s Import Wizard:

  • Import JSON to MongoDB
  • Import CSV to MongoDB
  • Import BSON/mongodump to MongoDB
  • Import SQL to MongoDB

5. Explore MongoDB data

Double-click on a collection in the Connection Tree to open a Collection Tab, which is the starting point of all data exploration in Studio 3T.

Here you can view the contents of your MongoDB collection in either Table View, Tree View, or JSON View:

Or access the Visual Query Builder, a drag-and-drop MongoDB query builder ideal for both newcomers and pros:

Once you’ve built your query, click on Query Code tab to see how it translates to Java, Node.js, PHP, C#, Python, Ruby, and the mongo shell language:

And that’s just one way of querying data in Studio 3T. There’s also IntelliShell, the built-in mongo shell with robust auto-completion; Aggregation Editor, the stage-by-stage aggregation query builder; and SQL Query, which lets you write SQL to query your MongoDB database.

Related reading

  • A roundup of the best MongoDB Atlas tools for data migration, data modeling, performance tuning, and more
  • Tips on how to reduce your MongoDB Atlas monthly bill
  • Find MongoDB tutorials in Academy 3T
  • Search for MongoDB tutorials in the Studio 3T Knowledge Base
  • Pressed for time? Subscribe to the Studio 3T YouTube Channel for quick MongoDB tips, tricks, and how-tos

How helpful was this article?
This article was hideous
This article was bad
This article was ok
This article was good
This article was great
Thank you for your feedback!

About The Author

Kathryn Vargas

When she's not writing about working with MongoDB, Kathryn spends her free time exploring Berlin's food scene, playing the drums, learning languages (current mission: German), and hiking.

Article navigation

Related articles

  • How to install a local MongoDB on macOS and connect to Studio 3T
  • Connecting Studio 3T to DigitalOcean Managed MongoDB
  • 5 Reasons You Should Install A Local MongoDB Database

Studio 3T

MongoDB Enterprise Certified Technology PartnerSince 2014, 3T has been helping thousands of MongoDB developers and administrators with their everyday jobs by providing the finest MongoDB tools on the market. We guarantee the best compatibility with current and legacy releases of MongoDB, continue to deliver new features with every new software release, and provide high quality support.

Find us on FacebookFind us on TwitterFind us on YouTubeBrowse our communityFind us on LinkedIn

Education

  • Free MongoDB Tutorials
  • Connect to MongoDB
  • Connect to MongoDB Atlas
  • Import Data to MongoDB
  • Export MongoDB Data
  • Build Aggregation Queries
  • Query MongoDB with SQL
  • Migrate from SQL to MongoDB

Resources

  • Feedback and Support
  • Sales Support
  • Knowledge Base
  • Community
  • FAQ
  • Reports
  • White Papers
  • Testimonials
  • Discounts

Company

  • About Us
  • Blog
  • Careers
  • Legal
  • Press
  • Privacy Policy
  • EULA

© 2023 3T Software Labs Ltd. All rights reserved.

  • Privacy Policy
  • Cookie settings
  • Impressum

We value your privacy

With your consent, we and third-party providers use cookies and similar technologies on our website to analyse your use of our site for market research or advertising purposes ("analytics and marketing") and to provide you with additional functions (“functional”). This may result in the creation of pseudonymous usage profiles and the transfer of personal data to third countries, including the USA, which may have no adequate level of protection for the processing of personal data.

By clicking “Accept all”, you consent to the storage of cookies and the processing of personal data for these purposes, including any transfers to third countries. By clicking on “Decline all”, you do not give your consent and we will only store cookies that are necessary for our website. You can customize the cookies we store on your device or change your selection at any time - thus also revoking your consent with effect for the future - under “Manage Cookies”, or “Cookie Settings” at the bottom of the page. You can find further information in our Privacy Policy.
Accept all
Decline all
Manage cookies
✕

Privacy Preference Center

With your consent, we and third-party providers use cookies and similar technologies on our website to analyse your use of our site for market research or advertising purposes ("analytics and marketing") and to provide you with additional functions (“functional”). This may result in the creation of pseudonymous usage profiles and the transfer of personal data to third countries, including the USA, which may have no adequate level of protection for the processing of personal data. Please choose for which purposes you wish to give us your consent and store your preferences by clicking on “Accept selected”. You can find further information in our Privacy Policy.

Accept all cookies

Manage consent preferences

Essential cookies are strictly necessary to provide an online service such as our website or a service on our website which you have requested. The website or service will not work without them.

Performance cookies allow us to collect information such as number of visits and sources of traffic. This information is used in aggregate form to help us understand how our websites are being used, allowing us to improve both our website’s performance and your experience.

Google Analytics

Google Ads

Bing Ads

Facebook

LinkedIn

Quora

Hotjar

Reddit

Functional cookies collect information about your preferences and choices and make using the website a lot easier and more relevant. Without these cookies, some of the site functionality may not work as intended.

HubSpot

Social media cookies are cookies used to share user behaviour information with a third-party social media platform. They may consequently effect how social media sites present you with information in the future.

Accept selected
✕