Creating a local network between two computers without a router or cable is a task that often arises when you need to quickly transfer large amounts of data. When you don't have a flash drive handy, and mobile internet or cloud storage speeds aren't up to par, a direct connection via Wi-Fi becomes the ideal solution. This method allows you to share files, play games, or even share a printer using only the built-in wireless modules of your devices.
Modern operating systems such as Windows 10 And Windows 11, have built-in tools for implementing this feature, but standard security settings often block device discovery by default. You don't need to purchase additional hardware or install complex drivers. Simply configure the network profile settings correctly and enable discovery in the system to turn one computer into an access point or connect both to the same virtual network.
In this article, we'll explore all the nuances of setting up such a connection, from choosing a network topology to fine-tuning folder access rights. We'll cover the computer-to-computer (Ad-Hoc) method, which has been the standard for many years, and a more modern approach using a virtual access point, which is relevant for the latest OS versions. Understanding these principles will allow you to easily manage your home network in any environment.
Selecting a connection method and preparing equipment
Before setting up, you need to decide on the device interaction scheme. There are two main scenarios: a direct connection without intermediary equipment (Ad-Hoc or computer-to-computer mode) and connecting both PCs to the same wireless network via a router. The first option is ideal if you don't have access to a router or are in the field. The second option is more stable and preferable for permanent use in the office or at home.
To implement any of these scenarios, your computers must be equipped with working Wi-Fi adapters. Most modern laptops have a module built in by default, while desktop PCs may require an external USB dongle or PCI card. It's critical to ensure the device drivers are installed correctly and that the adapter supports "Monitor" mode or virtual access point creation, which is especially important for older network cards.
⚠️ Attention: When connecting directly without a router, the network range may be significantly shorter than usual. Ensure that computers are within line of sight or no more than 5-7 meters apart to ensure a stable signal.
It's also worth considering the operating system version. Although the setup principles are similar for Windows 7, 8, 10, and 11The menu locations and names of some options may differ. For example, in newer versions of Windows, the Network control panel has been partially moved to the Settings app, which can sometimes be confusing for users accustomed to the classic interface. Therefore, it's important to carefully follow the navigation paths we provide in the instructions.
Setting up a Computer-to-Computer (Ad-Hoc) Network in Windows
Ad-Hoc technology allows you to create a decentralized network where devices connect directly to each other. Older versions of Windows had a wizard to create such a connection, but in Windows 10 and 11 Microsoft has removed the graphical interface for this feature, leaving the option to configure it via the command line. This requires more attention to detail, but provides flexibility in managing network settings.
First, you need to run the command prompt as administrator. This can be done by finding cmd in the search by right-clicking and selecting the appropriate option. The first step is to check hosting support. Enter the command netsh wlan show drivers and look for the line "Hosted Network Support." If it says "Yes," your adapter is ready to use. If it says "No," you may need to update your drivers or replace your adapter.
The next step is creating the network itself. You'll need to specify a name (SSID) and password. The command has the following format, which you'll need to enter into the console:
netsh wlan set hostednetwork mode=allow ssid=MyNetworkName key=MyPassword123
Once the command is successfully executed, the network will be created but not yet running. To activate, enter netsh wlan start hostednetworkNow on the second computer, the hotspot you created with the name will appear in the list of available Wi-Fi networks. MyNetworkNameBy connecting to it from a second PC, you establish a local connection. However, for the computers to "see" each other for file sharing, additional sharing configuration is required, which will be discussed below.
What to do if the command fails?
If the system reports that the service is not running, press Win+R, enter services.msc, find "WLAN AutoConfig Service," and make sure it's running. Also, try temporarily disabling your antivirus software, as it may be blocking the creation of virtual adapters.
Establishing a connection via a virtual access point
A more modern and convenient analogue of Ad-Hoc is the Mobile Hotspot mode, available in Windows 10 and 11This method turns your computer into a fully-fledged Wi-Fi router, distributing internet (if available) and creating a local network for other devices. This solution is more stable and easier to manage, as it doesn't require complex commands.
To activate this feature, go to the menu Start → Settings → Network & Internet → Mobile hotspotHere, you need to select the network you'll use for internet access (if applicable) and set a name and password for the new network. Toggle the slider to "On." Now the second computer can connect to this network just like a regular home Wi-Fi hotspot.
A key advantage of this method is the automatic configuration of security protocols. The system automatically selects the optimal encryption standard (usually WPA2-Personal), protecting your data from interception, unlike older Ad-Hoc methods, which sometimes worked in open mode. Furthermore, this mode makes it easier to control connected devices through the settings interface.
Setting up sharing and device discovery
Even if the computers are successfully connected via Wi-Fi, you may encounter a situation where they don't see each other in the network neighborhood. This is a standard Windows security behavior, which blocks detection on public networks. To fix this, change the network profile from "Public" to "Private."
Do this on both computers. Go to Settings → Network & Internet → Status (or "Wi-Fi" / "Ethernet" depending on the version). Click the active connection properties and select the "Private" network type. This will make your computer visible to other devices and open ports for local data exchange.
Next, you need to configure the sharing settings. Open Control Panel → Network and Internet → Network and Sharing Center → Change advanced sharing settingsIn the "Private" profile, follow these steps:
- ✅ Enable network discovery
- ✅ Enable file and printer sharing
- ✅ Allow Windows to manage HomeGroup connections
In the "All Networks" section, we recommend enabling password-protected sharing if you're in a secure environment, or disabling it for easier access if your network is completely isolated. After applying the settings, it's recommended to restart both computers for the changes to take effect and for services to update their lists.
☑️ Check network settings
Empowerment: Resource Sharing
Once successfully connected, you have a wide range of options. You can share any folder on one computer, making it readable or writable from the other device. To do this, right-click the folder, select Properties → Access → Advanced settings and check the "Share" box. Here you can also configure permission levels for different users.
In addition to file sharing, this type of network is also convenient for co-op gaming over a local area network (LAN). Many classic and modern games support this mode, allowing you to play together without the lag typical of online servers. Simply launch the game on both PCs, create a server on one, and find it using the local network search on the other.
Remote desktop support is also possible. If you need to control one computer from another, use the built-in app. Remote Desktop Connection. Enter the IP address of the target computer (which can be found using the command ipconfig (in the command line) and connect using your user credentials. This allows you to work with files and programs on the remote PC as if you were sitting right in front of it.
| Parameter | Ad-Hoc Mode (Direct) | Mobile hotspot | Via a router |
|---|---|---|---|
| The need for a router | Not required | Not required | Required |
| Difficulty of setup | High (console) | Low (GUI) | Average |
| Connection stability | Average | High | Maximum |
| Internet access | Only if shared | Automatically | Everyone has one |
Solving typical problems and diagnostics
Despite the apparent simplicity, users often encounter connection errors. One of the most common issues is when computers see the network but cannot obtain an IP address or data exchange fails. This is often resolved by manually entering IP addresses. In the protocol properties Internet Protocol version 4 (TCP/IPv4) Select "Use the following IP address".
Set addresses in one subnet, for example: for the first computer 192.168.137.1, for the second 192.168.137.2The system will automatically enter the subnet mask (255.255.255.0). You can leave the gateway blank, or specify the address of the first computer if you plan to access the internet through it. This eliminates addressing conflicts that often arise with automatic DHCP distribution.
⚠️ Attention: Third-party antiviruses and firewalls (Kaspersky, ESET, Avast) may block the local connection, considering it suspicious. If your Windows settings are correct but there's no connection, try temporarily disabling the firewall or adding your local network to the trusted list in your antivirus settings.
Another common issue is the error "Windows cannot access...". Make sure the service is enabled on both computers. Function Discovery Resource PublicationFind it in the list of services (command services.msc), set the startup type to "Automatic" and start the service. This is a critical component for displaying your computer in the network neighborhood in newer versions of Windows.
Frequently Asked Questions (FAQ)
Is it possible to connect a Windows computer and a MacBook via Wi-Fi?
Yes, this is possible. However, direct ad-hoc connections between Windows and macOS can be challenging due to differences in protocol implementation. It's best to connect both devices to a single router. If you don't have a router, you can create a network on your Mac and have Windows attempt to connect to it, but it's often easier to use third-party file sharing software, such as Resilio Sync or Syncthing, which work on top of any connection.
What is the maximum data transfer rate for this connection?
Speed depends on the Wi-Fi adapter standard (802.11n, ac, ax) and distance. Under ideal conditions, using the 802.11ac (Wi-Fi 5) standard, actual file transfer speeds can reach 20-40 MB/s (megabytes per second), which is significantly faster than USB 2.0 but slower than a gigabit cable.
Is it safe to transfer files over the created network?
If you set a strong password on your Wi-Fi network (WPA2/WPA3), it's virtually impossible for anyone to intercept your data from the outside. However, other connected devices can theoretically see your open folders within the network. Always use password protection and don't grant access to your entire drive, only to specific folders.
Why doesn't the second computer see the first one in the network environment?
Check three things: 1) The network profile should be "Private" on both PCs. 2) The discovery service should be enabled. 3) Try accessing the file through File Explorer by entering the IP address in the address bar in the format \\192.168.1.5Often, directly entering an address works even if the computer icon is not displayed in the list.
Is it possible to play online games over this connection?
Connecting two PCs alone doesn't provide internet access. However, if one computer has network access (via Ethernet or a 4G modem), it can share that internet connection via a Wi-Fi hotspot, giving the other PC online access.