If you 'upgraded' from Windows 7 to Windows 8 or directly to Windows 8.1, you might have noticed that ad hoc Wi-Fi (computer-computer) connections are no longer available. The user interface for setting up an ad hoc connection does not exist any more in the Network and Sharing Center. This can be a bit disappointing. However, with Windows 7 itself, a substitute feature was introduced which is a better replacement for ad hoc wireless connections.
Instead of ad hoc connections, you should use the Wireless Hosted Network feature. It makes your Windows PC behave like a wireless access point.
The wireless Hosted Network is a new WLAN feature supported on Windows 7 and later client versions and on Windows Server 2008 R2 and later Windows Server releases. This feature implements two major functions:
- The virtualization of a physical wireless adapter into more than one virtual wireless adapter sometimes referred to as Virtual Wi-Fi.
- A software-based wireless access point (AP) sometimes referred to as a SoftAP that uses a designated virtual wireless adapter.
As you can see, this can fully serve as the replacement for ad-hoc connections.
Start by opening the command prompt as administrator. The best way to perform this on Windows 8 is the Power Users Menu: press Win+X keys on the keyboard and choose the "Command Prompt (Admin)" item. On Windows 7, type: cmd into the Start Menu search box and press Ctrl+Shift+Enter.
Before you set up the Hosted Network, you must ensure that your wi-fi network card meets the requirements. It must have the correct drivers installed for this feature to be enabled. At the elevated command prompt, type this:
netsh wlan show drivers
Notice the string "Hosted network supported". It must contain "Yes". Otherwise, you are out of luck - your wireless adapter drivers do not support the hosted network feature.
To set up the Hosted Network, type the following command:
netsh wlan set hostednetwork mode=allow ssid=”DESIRED_NETWORK_NAME” key=”YOUR_PASSWORD”
Voila, you just created a hosted network. It is as simple as that. Now, you have to start it. The following command will do this for you:
netsh.exe wlan start hostednetworkname
When you are finished with it, you can stop the connection using this command:
netsh.exe wlan stop hostednetworkname
Note that the network will not be started permanently and will disappear after reboot until you start it again. However, by default, the stored passphrase/key will be persistent.
You can get detailed information about the network you started with this command:
netsh wlan show hostednetworkname
That's it. Easy, right? Although Microsoft has removed the ad hoc wireless networking feature from modern Windows versions, this simple trick can make up for the missing feature for everyone who quickly needs to get wireless devices to connect.