Loading

Quipoin Menu

Learn • Practice • Grow

mongodb / Installing MongoDB
tutorial

Installing MongoDB

Before you can start using MongoDB, you need to install it on your computer. Don't worry – it's simple! You have two options: install MongoDB locally on your machine, or use MongoDB Atlas (cloud version). Let's learn both.

Option 1: Installing MongoDB Locally

Go to the official MongoDB website: MongoDB Community Server

Windows Installation:
  1. Download the .msi installer for Windows.
  2. Run the installer and follow the setup wizard.
  3. Choose "Complete" installation type.
  4. Make sure "Install MongoDB as a Service" is checked.
  5. Complete the installation.

Mac Installation (with Homebrew):
brew tap mongodb/brew
brew install mongodb-community
brew services start mongodb-community

Linux (Ubuntu) Installation:
wget -qO - https://www.mongodb.org/static/pgp/server-6.0.asc | sudo apt-key add -
echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-6.0.list
sudo apt-get update
sudo apt-get install -y mongodb-org
sudo systemctl start mongod

Verify Installation:
mongod --version
mongo --version

Option 2: MongoDB Atlas (Cloud - Recommended for Beginners)

MongoDB Atlas is a cloud database service. It's free and you don't need to install anything!
  1. Go to MongoDB Atlas
  2. Click "Try Free" and sign up.
  3. Choose the FREE shared cluster (M0).
  4. Select your cloud provider (AWS, Google Cloud, or Azure) and region.
  5. Click "Create Cluster" (takes 1-3 minutes).
  6. Set up database user (username and password).
  7. Add your IP address to the IP Access List.
  8. Click "Connect" and get your connection string.

Your Atlas Connection String Looks Like:
mongodb+srv://username:password@cluster0.abcde.mongodb.net/myFirstDatabase

Two Minute Drill

  • You can install MongoDB locally or use MongoDB Atlas (cloud).
  • Atlas is easier for beginners – no installation needed.
  • Local installation steps vary by operating system.
  • After installation, verify with `mongod --version`.
  • Save your Atlas connection string – you'll need it to connect.

Need more clarification?

Drop us an email at career@quipoinfotech.com