Setting up MongoDB on Windows

For a full overview of MongoDB and all my posts on it, check out my overview.

MongoDB can be quickly and easily set up on Windows using the default MSI installation wizard provided by the MongoDB team.

To get the installer, follow these steps:

  • Go to the MongoDB Download Center
  • Choose a specific version of MongoDB to install if you wish, otherwise, just leave it on the default version
  • For Platform, choose Windows
  • For Package, choose server
  • Click the Download button

Once the installer has finished downloading, go ahead and run it.

  • Choose your setup type - choose Complete if you don't want to choose what gets installed. If you do want to choose, select Custom
  • For the Service Configuration, if you want MongoDB to be managed as a Windows Service and start automatically, tick the box for Install MongoDB as a Service. ( I assume MongoDB is set up as a service for this tutorial)
You can choose to have a default Window Network User manage the service or you can customize the service setup
  • If you want to install Mongo Compass, a GUI application for interacting with your MongoDB data, you can do so as well.
  • Once installation is complete, MongoDB will already be running and accessible.

Once MongoDB is running, it will be available at mongodb://localhost:27017. You can connect to it using various tools such as mongosh, Mongo Compass, or any programming language using a module for MongoDB.


Did you find this information useful? If so, consider heading over to my donation page and drop me some support.

Want to ask a question or just chat? Contact me here