MongoDB is a popularly used NoSQL database. It is widely used for web application development and real-time storage. In this tutorial on MongoDB Installation on Windows, you will walk through the step-by-step installation and setup process of MongoDB.
Now that you know what’s in store, continue reading the article, to dive deep into this topic.
A Step-by-Step Guide to MongoDB Installation on Windows
Navigate to the download site
Navigate to the official MongoDB website.
Cross-check the Specifications and Download MongoDB
Under the Software section, click on the Community server version.
Make sure that the specifications to the right of the screen are correct. At the time of writing, the latest version is 4.4.5. Ensure that the platform is Windows, and the package is MSI. Go ahead and click on download.
You can find the downloaded file in the downloads directory. You can follow the steps mentioned there and install the software.
On completing the installation successfully, you will find the software package in your C drive. C:\Program Files\MongoDB\Server\4.4\bin.
You can see that there are mongo and mongod executable files. The mongod file is the daemon process that does the background jobs like accessing, retrieving, and updating the database.
Create an Environment Variable
It’s best practice to create an environment variable for the executable file so that you don’t have to change the directory structure every time you want to execute the file.
Execute the Mongo App
After creating an environment path, you can open the command prompt and just type in mongo and press enter.
The mongo server is then generated and is up and running.
Verify the Setup
To verify if it did the setup correctly, type in the command show DBS.
With that, you have successfully installed and set up MongoDB on your Windows system.
This demo sample has also created a database called mydatabase, with some data added to it. It has also displayed the same using the find() method.
In the upcoming articles, you will learn more about MongoDB and how to work with it.
We hope this article on MongoDB Installation on Windows has helped you. If you wish to make a career as a developer, then certification will come in handy.
Simplilearn’s MongoDB Certification Training Course will help you master popular and essential topics like query, ingestion, sharding, data modeling, and data replication with MongoDB, along with the installation, update, and maintenance of the MongoDB environment. This course will also help you gain high-level proficiency in handling MongoDB configuration and backup methods, and the required monitoring and operational strategies.
Have any questions for us regarding MongoDB? Please place them in the comments section of this page, and our industry experts will get back to you soon!