Guide to create a hosted network using the command prompt in Windows 10 PC. The same steps can be applied to Windows 7 and Windows 8.1 running PCs. This guide will help you to create a Wi-Fi hotspot in Windows 10 PC using the command prompt and without any third party software utility.
Most of us have a wired internet connection on our PC. I have been using a 3G dongle for a few years now. However, if you have a wired internet connection or if you use the internet through 3G or 4G dongle on your PC, you can share the Internet by creating a Wi-Fi hotspot in Windows 10.
The hosted network feature in Windows 10 allows you to create a Wi-Fi hotspot and then share it with your other Wi-Fi-enabled devices such as tablets, smartphones, and laptops or PCs which has Wireless connectivity cards installed.
Related Articles:
Microsoft does not provide any direct UI to create a Wi-Fi hotspot in Windows 10, but you can create it using a few lines of commands. Here is how to create a Wi-Fi hotspot in Windows 10 using the command prompt method.
Create Wi-Fi Hotspot in Windows 10 using Command Prompt
Step 1: Create Wi-Fi Hotspot
To create a Wi-Fi hotspot, you should have a wireless card installed on your laptop. Begin with turning on Wi-Fi on your PC or Laptop. You can find a dedicated Wi-Fi button on your laptop or click on Notification Center in Windows 10 and turn on Wi-Fi.
Next, open an elevated command prompt (command prompt as administrator).
Open a command prompt using Run – Press Windows Key + R and type in cmd in the Run dialogue box and hit enter.
Open Command prompt from Start – Right-click on the Start button and select Command Prompt (Admin). This should open the command prompt in administrative mode. Or press Windows key + X and select Command Prompt (Admin).
In the command prompt Window, type the following command:
netsh wlan set hostednetwork mode=allow ssid=MyWi-Fi key=yourpassword
In the above command, “MyWi-Fi” is your Wi-Fi hotspot name and “yourpassword” will be your password. Change it according to your needs.
Press enter to create the hosted network. If the hosted network is created successfully, you should see a success message.
Step 2: Start the Wi-Fi Hotspot
Now you need to start the hosted network, to do this type the following command:
netsh wlan start hostednetwork
This will start the hosted network on your PC and a connection named MyWi-Fi (or whatever you named it) will appear in the Network Connection list.
The next step is to share the existing internet connection with a newly created Wi-Fi hotspot.
Go to Control Panel, Network and Internet and open Network Connection. Or copy and paste this “Control Panel\Network and Internet\Network Connections” in Windows Explorer.
Right-click on your existing internet connection and select Properties. In my case, it was Mobile Broadband Connection 3.
From the properties window, click on the Sharing tab.
Now check “Allows other network users to connect through this computer’s Internet connection.”
Click on “Select a Private Network” and select the newly created Wi-Fi connection from the drop-down list.
Click on the OK button to save the settings and close the properties window.
Now if you go to the Network and Sharing Center in Control Panel, you will see your newly created Wi-Fi connection listed in the active networks section.
That’s it! Take out your phone, tablet, and laptop and start using the Wi-Fi. You can stop Wi-Fi connection either by disabling Wi-Fi (Turning OFF Wi-Fi) or by typing “netsh wlan stop hostednetwork” command in command prompt.
Whenever you want to start the Wi-Fi network, open the command prompt as Administrator and type in “netsh wlan start hostednetwork” command.
To Read About- Tubemate App Click Here
Update:
If you don’t want to enter the ” netsh wlan start hostednetwork” command each time to start the WiFi hotspot, you can create a batch file (.bat) to execute this command with a single click. I have already created a batch (.bat) file to start the WiFi hotspot, and you can download it from here.
Related Articles:
-
Download Nintendo 3Ds Emulator for Windows 10
-
How to Fix Chrome Browser ERR_CONNECTION_RESET Error Problem
Place the downloaded batch file on your desktop. Double-clicking on the batch file will start your WiFi Hotspot. When you double-click on it, a command prompt window will appear notifying you that the WiFi hotspot has been started. You can press any key to close the window.
Note: If you download the batch file and try to run it, Windows will show a security warning as the file has .bat extension. You can safely ignore the warning as the file safe to use.
Wi-Fi Hotspot Troubleshooting tips:
Wi-Fi hotspot is showing connecting, but don’t connect – This happens when you haven’t shared your existing internet connection with the WiFi hotspot. Go to Control Panel, and navigate Control Panel\Network and Internet\Network Connections.
Right-click on an existing internet connection, select Properties, go to Sharing tab, select your Wi-Fi hotspot from the drop-down list and click on OK to save the settings.
Open the command prompt and start the Wi-Fi hotspot with “netsh wlan start hostednetwork” command.
The hosted network couldn’t be started – This error can occur due to several reasons. We have a detailed guide covering how to fix the hosted network couldn’t be started error. Follow the link and you will be able to resolve the issue.
Note: You can always create a new Wi-Fi hotspot using the same command. Every new Wi-Fi connection will overwrite the previous one.
This was about how to turn your Windows 10 Computer into a Wi-Fi hotspot. Do let us know your thoughts in the comments below.
It’s very helpful for me ………….
Thnx…………..
Do i need to do it every time I start my laptop?
Hi Umesh, you don’t need to create WiFi hotspot every time. Once you have setup the Virtual WiFi hotspot using the command prompt, you only need to turn it On / Off after the restart.
To turn On the WiFi hostpot, open command prompt and enter Netsh wlan start hostednetwork
And if you want to turn it off enter Netsh wlan stop hostednetwork
If you don’t want to enter the command each time, you can create a Batch file to run these command with a single click.
You can find the link to download Batch file to Turn On WiFi hotspot in the article.
Whenever I start sharing wifi, My notebook force shutdown itself around 10 mins later. How to fix this?
plz it asks me for password but i didn’t add any password when setting it up
pla what password should i use
Hi,
If you have entered the command given in the article then, you must have set default password (example password given in the article). enter password as yourpassword and see if that works.
Oh yeah! Well done. Thank you very much.
My Lenovo Miix 3 with Win 10 now can share internet connection from 3G mobile network to wifi. It’s running well.
great to hear that Cuong.
But after some time it drops connection nd do not connect again
I try to share 3g connection,but have only a note your internet connection is unstabile..
Hi Martin, I am not sure, but that looks to be a problem with your internet connection/network operator itself. Because I am able to share my 3G connection perfectly fine.
hey..
I followed all the above mentioned procedure to set up laptop as wifi hot-spot. This created my-wifi network and is showing in my android phones wi-fi list also , but there is a message of “No internet access ” even after allowing this wifi for all users.
How to resolve this issue..??
Did you share you internet connection with your newly created WiFi Hotspot in Control Panel?
I’m also facing the same issue.
though I m connected to the created my wifi but there is no internet connection that is I can’t use the internet
yes..I did
followed all the steps and i can see hotspot name in my phone but couldn’t connect to it as it says obtaining IP address and is not connecting to the hotspot at all….
Make sure you have shared the internet connection with the newly created WiFi Hotspot.
exact problem here,.,
The hosted network couldn’t be started.
The group or resource is not in the correct state to perform the requested operation.
command prompt could not start the network .. any help there ?
i dont know why but it doesnt mork out for me i am told “The hosted network couldn’t be started the group or the resource isn’t in the correct state to perform the requested operation”
What do i do? i reali need help please
There is no drop down list when I click ” Allow users to connect through this computers internets connection. ” It stays default with “Ethernet”
Hello,
I’m facing the same issue as faced by darshana. Could you please let us know how to resolve it.
wi-fi is connected to my phone but its give error that “No internet connection”.
I’m using MI3 phone.
Thanks
Everything was okay, but it is not connecting to my mobile…..
Make sure you have shared your internet connection with the newly created WiFi Hostpot.
Hello,
I’m facing the same issue as faced by darshana & Pravej. Could you please let us know how to resolve it for window 10. Wi-Fi is connected to my phone but its give error that “No internet connection”. I’m using SAMSUNG & MOTO phone.
Everything is okay, Wi-Fi is connected in my mobile but unable to use Internet in my mobile. Please help.
hi,
i am using netgear for wifi..can i create wifi hotspot in my laptop. I tried but i didnot work. will u pls help me?
What problem you are facing?
do this work fr windows 8.1??? There is no drop down list when I click ” Allow users to connect through this computers internets connection. ” It stays default with “wifi” cant even edit on it
Simply check the box and leave the default option. See if that works.
It doesnt connect bro, it says obtaining IP address then after sometime it says IP Configuration Failure
Make sure you have entered correct password. Also make sure you have shared the internet connection with the newly created WiFi Hotspot.
i also try but my laptop stop joining to other networks when i connected to another wifi it shows unidentified network n no internet access. when i stop hostednetwork then it connects to wifi…please help
After i did it now my wifi on laptop is getting connected but says no internet access how to make it back to normal?
I have done everything but it is not working on phone. connected but not working
Hi dr tashreef
I’m satarted wifi hotspot in windows 10 command prompt
I enter this netsh wlan show driver.
There’s come big list but than readed all of list there’s
Showing like Hostednetwork supported yes/no but my laptop showing “no”
So wat can I do for this pls do u have any idea pls..
Thank you for sharing this. It was easy to understand & it works with my win 10 & win xp computers, even lets me share files. The .bat file is a dream.
Hey, there is no wifi option coming in my windows 10.
my ethernet is not showing drop down option in sharing tab. i am unable to select created hosted network. what should i do?
first uncheck Allow other network users to connect through this computer’s connection option and click on OK to save the settings. Now start WiFi hotspot using Netsh wlan start hostednetwork command. Now go back to Internet and sharing settings, check Allow other network users to connect through this computer’s network and from the drop down menu below select your WiFi hotspot.
Note: Your WiFi hotspot will only appear if you have already started the hosted network using the command.
hey !! the newly created network donot shows up in the sharing tab. it only shows the ethernet. PLS help me
I am having a problem I my PC wifihotspot that is when i am giving a command in my command promt the wifi is producing that i can see in my phone but when i am connecting my phone to it it is not connecting and just showing obtaining IP address and then after a mintue it is dissconnected without connecting…..as I am having internet wire connected to my laptop that is ethernet…
Hi, please check your command for stopping the network.
It says: netsh wlan stop wlan stop hostednetwork
Shouldn’t it be just: netsh wlan stop hostednetwork
That’s right Vipul. It has been corrected now. Thanks for the input.
wouldnt work for dongle connections like mts and etc :C idk wt to do you got any ideas? it is working for lan though but i wanna use dongles
Hi, I am using a dongle my Self (Huawei 3G) and it works perfectly fine.
Hi dr tashreef
I’m careated wifi hotspot in commond prompt admin in windows 10 Lenovo
It’s k its satarted but it’s not connecting the other devices it’s showing obtaingip address
Do u have any idea for this pls
my laptop doesnt support hosted network.
what to do
If it does not support Hosted network, you may need to get a WiFi dongle or WiFi adapter. They are available cheap online.
What kind of stupid website is this, which gives few lines of command line codes and does not allow to copy it? Why would someone bother to type the code, it has chances of mistakes.
Hi Sandeep Sorry for disabling copy function. We are dealing with some content scrappers, hence had to disable it temporarily.
Try now, it should be working fine.
I accidentally disabled the hosted network by going to “Control Panel\Network and Internet\Network Connections” and i find no way to again create hotspot…would you please help me out
please help me to start my hotspot.
its shows that resources or group is not in correct state.
In windows 7 my hotspot software was working perfectly…..after i upgraded to windows 10 it does,t work……… i also tried the above command but the error message is that “your system wireless card does not support wireless hotspot “…….please help if any one experienced with this kind of issue.
Hi, it could be a driver issue. Visit your Laptop makers website and look for any drivers released for WiFi Card for Windows 10 running PCs.
Very nicely explained and very informative with troubleshooting guide link available.
i followed to procedure correctly but in the sharing network part,there is not drop down list to enable me share my newly created hostednetwork what should i do?
thanx a lot, it worked..but i want to see the password
for this what should be typed in command prompt.
what is the use?
Hi Ramesh, the use is that you can share your PCs internet connection with your WiFi-enabled devices through a WiFi Hotspot. Basically, you don’t need a WiFi Router for the task.
sir I have forget my netsh password. how i would able to know or get that password ????
Hi Rajesh, try creating a new Hotspot using the command prompt with a new username and password and it will overwrite your old Hotspot credentials.
how to create new username and password?
Hi Ramesh, It is similar to how you have done it for the first time.
Open command prompt and enter following command:
netsh wlan set hostednetwork mode=allow ssid=Mi-WiFi key=yourpassword
Replace Wi-Fi with what you want to name your Hotspot and replace yourpassword with the password you want and hit enter.
That’s it.
i have tried every step but could not get the internet even if it shows connected and i have also reached till last step where private network has been started..please help me
Hi sidhharth, if you are unable to connect to the internet on your phone then check whether you have shared your internet connection with your newly created WiFi Hotspot.
Go to Control Panel>> Network and Internet >> Network and Sharing Center >> click on Change adapter settings >> Rigt-click on your current active internet connection and select Properties.
Under Properties window, click on Sharing tab and check the box “Allow other network users to connect through this PCs internet connection” and below that from the drop-down menu select your newly created WiFi Hotspot or hosted network. click on OK to save the settings. Now try connecting through your phone.
I have done all the steps but when i try to connect my hostednetwork with any device it doesn’t get connected it keeps on showing connecting
Hi Kaushak, try doing this >> Go to Control Panel>> Network and Internet >> Network and Sharing Center >> click on Change adapter settings >> Right-click on your current active internet connection and select Properties.
Under Properties window, click on Sharing tab and check the box “Allow other network users to connect through this PCs internet connection” and below that from the drop-down menu select your newly created WiFi Hotspot or hosted network. click on OK to save the settings. Now try connecting through your phone.
this is an excellent innovation. waaw am loving it
Great to hear that Basiru, glad You did found it useful. However, Microsoft added this hostednetwork back when Windows 7 was released and then continued with latest versions. Indeed a very useful feature to have.
Dear Tashreef Shareef, thank you for the article.
I would like to send files from my laptop to my android smartphone (connected to the network created by my laptop). Do you know how to do that?
Thank you.
Hi Luiz, Try Air Droid.
Dear sir,
there is no newly created Wi-Fi connection listed in active networks section
help me
and also tell me how to check that who is connected to my Wi-Fi hotspot
If you don’t see your newly created WiFi hotspot, make sure that:
You have started the Hostednetwork using the command netsh wlan start hostednetwork
As of now, there is no way (i know of) you can see how many are connected to the Hosted network.
open your CMD (i didnt try no useing admin)
type ‘netsh wlan show hostednetwork’
it will show you number of client
Dear sir
i have a problem here, i created the hostednetwork, yes i found my wi-fi i try to access it (I am using iPHONE),it has a tick beside my ssid but when i look at the top it don’t have the wifi logo,
i ask my friend try to acess( SAMSUMG) but he can’t even have a tick,
Beside i try Maryfi it said i didn’t have microsoft virtual wifi , i have update it and use admin to opne but still can’t start hotspot is this a problem of my computer or a problem when i set up
Hi, Try using older version of the Virtual Hosted Network drivers.
the problem had been solved (i didn’t try your method yet)
it seem i need to redo share network to hostednetwork every time when i start my computer no matter what thank you for your reply
Wi-Fi hotspot is showing . but in the Sharing tab I can’t find my Wi-Fi hotspot connection name from the drop-down list.
Hi Tashreef, great article but I’m coming across an unexpected problem.
First time I did this it worked just fine. The very next day (after a restart) I began to have difficulties sharing the internet, so I took a look at the settings and saw that sharing wasn’t enabled. Should be easy – simply enable sharing and select the hosted network, right?
The problem is every time I try to enable sharing and select the created hosted network, the properties window freezes as does explorer. I have to close the app COM Surrogate and restart Windows Explorer every time I try this, and the settings are never applied. Any ideas?
Did you try creating a new Hosted network using the command prompt? I am not sure if that would work but give it a try.
Alternatively, also try the following:
Run Diagnostics. Right click on your internet connection in Control and panel and select Diagnose. It will fix if found any problem with the device.
Power Management: Right-click on your Network, select Properties. Click on Configure button and go to the Power Management tab and uncheck the option “Allow the computer to turn off this device to save power”.
See any of these works.
doing exactly the same thing and it was working fine earlier. But after the anniversary update of windows 10 i.e. 1607 update, not working. hotspot created each time but, devices were unable to connect. Same issue with other softwares like mhotspot, connectify etc.
Checked every aspect like sharing etc, but all efforts in vain. Is there anyone who is doing this with windows 10 version 1607.
I am also having the same Problem. My Sony Xperia M Dual C2004 is not able to connect to my HP Pavilion p-001TX Laptop with Windows 10 1607 Anniversary Update. My Phone shows “Authenticating…” then “Obtaining IP Address…”, but it never connects. I’ve checked the box “Allow other network users to connect through this PCs internet connection”. My Password is also correct. I tried the other Power Saving Fix that Tashreef has made. Still no luck…I’ve tried mHotspot and Mobile Hotspot in the Windows 10 Anniversary Update. Nothing works. Please help…
Hi,
I have done everything as per your instruction. When I am going to ethernet Sharing Tab I can not see the local host network there is showing WiFi I can not change wifi to the created hot spot network because there is no drop down.
The hosted network couldn’t be started.
The group or resource is not in the correct state to perform the requested operation.???
this error is coming…after a long days sir…help me??
i will try to solve…but it is still coming
i did this also…bt not coming sir…
i dont have a “wireless-n wlan half mini card ” in my device manager
Which laptop (model/make) are you using?
15-AC124TU(model),HP laptop sir
in the sharing tab of properties of ethernet, when i make it allow and click ok it shows that ‘your connection is shared with ethernet_32769 . do you want to make it to ethernet instead?’
and when i click ok, the hosted network shows that internet is connected but any mobile doesn’t connect to that network.
Tashreef, I indeed successfully shared internet from my 3G device using the guide you have given. But my phone now can’t connect to the hotspot although the hotspot is shown as available wifi. I keep being told “can’t connect to MyWi-Fi”. Please what is the possible cause of this development?
please help to hide my hosted network ssid how to do?except me.
sir,
on mobile obtaining ip address is written, but does not get connected.
thanks man….
Welcome Ashu, Glad I could help.
Anyone ever do this without an actual internet connection? I have a product that needs a hotspot when users do not have an internet or other network connection at all. I’ve set up the Loopback adapter and it seems solid with two iDevices connected to it. Once we start introducing other devices, it all goes haywire. Sometimes connecting and assigning an IP right away, then dropping after a minute, or never giving an IP to the device. Have tried setting the WiFi Mode on the adapter to “Wifi” and it seems like we can get more devices to work, but not even cose to the 100 clients that the hostednetwork claims it can handle.
If hostednetwork isn’t supported you can try my “Wifi Direct Access Point” app available in Microsoft Store. It use WiFi Direct to create an Access Point and works with the new driver of Windows 10 (Wireless Card should support WiFi Direct).
It is also working when you get internet through wifi and want to share internet via ethernet !
It says network couldn’t be started.
The group or resource is not in the correct state to perform the requested operation
Thanks for the update. I will verify the content and modify it accordingly.
do it need to be paid ???? or just for free
Free
While trying to connect on mobile it is stuck @ obtaining IP address and nothing happens. Please help
no sharing option present in Wi-Fi properties in windows 10.
Is it possible to create multiple fake hotspots from pc using only one hardware to manupulate someone
Thanks, this helped me.