![](https://www.devildoxx.com/wp-content/uploads/2017/09/mongodb1.png)
In this web guide you will learn how to install mongodb (Mongo Database) on Window 10, 8 and 7. Mongo DB is basically a database in which we store data in a very large amount. It is totally different if we compare mongo db with MySQL. Mongo Database is basically used in websites in which data quantity is very high and needs speed for serving data. Let’s start installing Mongo DB on Windows 10, 8 and 7.
Steps to Install Mongo Database on Windows 10, 8 and 7
1. First download latest version of Mongo DB from their official website . When you open you will see many options for downloading. Just choose community server and select your operating system.
2. After download setup file right click on it and run as administrator. A window will open like below
![Mongo DB Installation Windows Screen Shot 1 Mongo DB Installation Windows Screen Shot 1](https://www.devildoxx.com/wp-content/uploads/2017/09/Mongo-DB-Installation-Windows-1.png)
3. Check Terms and conditions of Mongo DB and when you click next second window will open like below
![Mongo DB Installation Windows Screen Shot 2 Mongo DB Installation Windows Screen Shot 2](https://www.devildoxx.com/wp-content/uploads/2017/09/2017-09-20-at-22-53-01.png)
4. You can see two options one is complete installation and second is custom. To make it easy we will choose custom option so we can install it in root directory of your windows. When you click custom a window will open like below :-
![Mongo DB Installation Windows Screen Shot 3](https://www.devildoxx.com/wp-content/uploads/2017/09/Mondo-DB-Installation-Windows-3.png)
5. You can see browse button on right side of Location. Change Location from
C:\Program Files\MongoDB\Server\3.4\
![Mongo DB Installation Windows Screen Shot 4 Mongo DB Installation Windows Screen Shot 4](https://www.devildoxx.com/wp-content/uploads/2017/09/Mondo-DB-Installation-Windows-3.png)
to
C:\mongodb
![Mongo DB Installation Windows Screen Shot 5 Mongo DB Installation Windows Screen Shot 5](https://www.devildoxx.com/wp-content/uploads/2017/09/MongoDB-Windows-Installation-Location.png)
![Mongo DB Installation Windows Screen Shot 6 Mongo DB Installation Windows Screen Shot 6](https://www.devildoxx.com/wp-content/uploads/2017/09/MongoDB-Windows-Installation-6.png)
Then click on next button for proceeding the installation. Another window will open like below ..
![Mongo DB Installation Windows Screen Shot 7 Mongo DB Installation Windows Screen Shot 7](https://www.devildoxx.com/wp-content/uploads/2017/09/Mongo-DB-Windows-Installation-7.png)
Click on Install and wait till the installation is completed.
6. After installation open directory where you have install mongodb library that is C:\mongodb then open bin folder in it.
![Mongo DB Installation Windows Screen Shot 8 Mongo DB Installation Windows Screen Shot 8](https://www.devildoxx.com/wp-content/uploads/2017/09/MongoDB-Installation-9.png)
7. Copy the path C:\mongodb\bin then click on start menu and search for advance system settings and open it
![Mongo DB Installation Windows Screen Shot 9 Mongo DB Installation Windows Screen Shot 9](https://www.devildoxx.com/wp-content/uploads/2017/09/Mongo-DB-Installation-Part-2.png)
8. A new window will open that will show advance system settings for your operating system. Click on Environment Variables for adding mongo DB Path for global access.
![Mongo DB Installation Windows Screen Mongo DB Installation Windows Screen Shot 10](https://www.devildoxx.com/wp-content/uploads/2017/09/Advance-System-Settings-Mongo-DB.png)
9. A new window will open like below
![Mongo DB Installation Windows Screen Shot 10 Mongo DB Installation Windows Screen Shot 10](https://www.devildoxx.com/wp-content/uploads/2017/09/Environment-Variables-MnogoDB-1.png)
10. Click on Edit button as mention above screenshot then a window will open that allow you to add path
![Mongo DB Installation Windows Screen Shot 11 Mongo DB Installation Windows Screen Shot 11](https://www.devildoxx.com/wp-content/uploads/2017/09/Mongo-DB-Environmental-Path-1.png)
Paste your mongodb path in variable value as show above and click ok as shown in above screenshot.
10. Mongo DB Windows Installation is completed
Why we set environment variables for mongo db ?
For running mongo db you have to open installation folder and then open command prompt to run windows. But if you have set environment variable for mongo db then you don’t need to go installation folder just simple open cmd anywhere and run Mongo DB.
How to run MongoDB after setting environment variables ?
Just simply open command prompt by searching it on start menu or if you know shortcuts then go for it.
![Mongo DB Installation Windows Screen Shot 12 Mongo DB Installation Windows Screen Shot 12](https://www.devildoxx.com/wp-content/uploads/2017/09/Command-Prompt-Mongo-DB.png)
![Mongo DB Installation Windows Screen Shot 13 Mongo DB Installation Windows Screen Shot 13](https://www.devildoxx.com/wp-content/uploads/2017/09/cmd-mongodb.png)
Now run command “mongod” like below
Hit Enter some processing will start and ends like below
![Mongo DB Installation Windows Screen Shot 14 Mongo DB Installation Windows Screen Shot 14](https://www.devildoxx.com/wp-content/uploads/2017/09/Mongo-DB-Port-Listen.png)
mongod command will activate mongodb default port that is 27017 but it does not start mongodb. For starting mongodb just minimize current command prompt window and open another command prompt window.
When you open new command prompt window type mongo as shown below
![Mongo DB Installation Windows Screen Shot 15 Mongo DB Installation Windows Screen Shot 15](https://www.devildoxx.com/wp-content/uploads/2017/09/Mongo-DB-Install-command.png)
And hit enter to start mongo db.
![Mongo DB Installation Windows Screen Shot 16 Mongo DB Installation Windows Screen Shot 16](https://www.devildoxx.com/wp-content/uploads/2017/09/2017-09-21-at-11-39-24.png)
That’s it, you can see warnings just ignore it your mongo db is working fine. Warnings are due to anonymous starting mongo db . You can authenticate using username and password then these warnings will not show. We will discuss it in next tutorial.
How to check Mongo DB is running in Windows ?
For checking mongo db is working or not just open any browser and type address http://localhost:27017 you will see below screenshot
![Mongo DB Installation Windows Screen Shot 17 Mongo DB Installation Windows Screen Shot 17](https://www.devildoxx.com/wp-content/uploads/2017/09/Mongo-DB-Running.png)
If your mongo db not working then this link will not work. Be sure that both command prompt windows are open while using mongo db.
Category : Web Development