Have you noticed that your laptop appears on your Wi-Fi network under a strange or confusing name? It might be a standard name like DESKTOP-123ABC or User-PC, which was automatically assigned by the system. On a local network, such a name can cause confusion, especially if several devices are connected. Changing the computer's hostname not only simplifies network identification but also helps when setting up file sharing, printer access, or remote control.
In this article you will find step-by-step instructions for all popular operating systems: Windows 10/11, macOS And Linux (including Ubuntu And Debian). We'll also discuss why a laptop's name may not change on the network immediately after a reboot, how to check the current name via the command line, and what to do if new settings aren't applied. We'll also cover typical mistakes and ways to resolve them - for example, when the name is reset after a system update or conflicts with another device on the network.
If you've never changed your computer name before, don't worry: the process takes no more than 5 minutes and doesn't require any special skills. Just follow the instructions and take into account the nuances of your operating system. And for those who prefer automation, we'll provide commands for quickly changing the name using Terminal or PowerShell.
1. Why change the laptop's Wi-Fi network name?
Computer name (or hostname) is an identifier used on a local network to address a device. By default, operating systems assign random or generic names, which can be inconvenient for everyday use. Here are some reasons why you might want to change the name:
- 🔍 Easy identification: Instead of LAPTOP-5678FGH You can use a meaningful name, for example Ivan-Laptop or Office-MacBook.
- 📂 File sharingWhen setting up network folders or printers, it is more convenient to select a device by a user-friendly name rather than by IP address.
- 🔒 Security: Standard names can reveal information about the device model or OS version, making it easier for attackers.
- 🖥️ Remote control: Programs like TeamViewer or AnyDesk often display the name of the computer to connect to.
- 📡 Online conflicts: If there are two devices with the same name on the same network, connection errors may occur.
Additionally, some applications (such as local multiplayer games or streaming programs) use the computer name to create sessions. If it contains Cyrillic or special characters, this can lead to crashes. Therefore, it's best to use Latin characters and avoid spaces.
2. How to change the laptop name in Windows 10 and 11
IN Windows The process of changing the computer name is almost the same for both versions 10 And 11The main difference is the interface design. We'll look at both options, as well as an alternative method via PowerShell for experienced users.
Method 1: Through Windows Settings (GUI)
This is the simplest method, suitable for beginners. Follow the instructions:
- Open the menu
Startand selectParameters(gear icon) or clickWin + I. - Go to the section
System → About the system. - In the block Device specifications find the button
Rename this PCand press it. - Enter a new name (Latin characters, numbers, and hyphens only). Length: up to 15 characters.
- Click
Next, thenRestart now.
After rebooting, the changes will take effect. To check the new name, open a command prompt (Win + R → cmd) and enter:
hostname
Close all important programs
Save open documents
Make sure you have administrator rights
Remember the current name in case of a rollback-->
Method 2: Via PowerShell (for advanced users)
If you prefer the command line, use PowerShell:
- Launch
PowerShellas administrator (find in search, right-click →Run as administrator). - Enter the command to check the current name:
Get-ComputerInfo | Select CsName - To change the name, run:
Rename-Computer -NewName"NEW_NAME" -Restart(replace
NEW_NAMEto the desired, without quotation marks).
The command will automatically reboot the computer. This method is useful for administering multiple computers on a network or creating scripts.
Common Windows Errors and Their Solutions
Sometimes, after changing a computer's name on the network, the old one appears. Here are possible causes and solutions:
| Problem | Cause | Solution |
|---|---|---|
| The name did not change after reboot. | DNS cache on a router or PC | Do it ipconfig /flushdns in CMD or reboot the router |
| Error: "Name already in use" | Conflict with another device on the network | Check the names of all PCs on the network and choose a unique one. |
| The name is reset after the update. | Domain Policy (in corporate networks) | Contact your network administrator or use a local account. |
| You cannot enter Cyrillic characters. | Windows hostname limitation | Use only Latin characters, numbers and hyphens |
⚠️ Attention: In corporate networks with a domain Active Directory Changing the computer name may be blocked by security policies. Please check with your IT department before proceeding.
3. Change the laptop name in macOS (Monterey, Ventura, Sonoma)
On MacBook or iMac the process is a little different from Windows, but no less simple. In macOS There are three types of names that can be displayed on the network:
- 🖥️ Computer name (Computer Name) - used in the local network.
- 📡 Local host name (Local Hostname) — for Bonjour services (e.g. AirDrop).
- 🌐 Internet name (Network Name) - for remote access.
We'll focus on the first item, as it's the one that appears in the list of Wi-Fi devices. This guide is relevant for macOS Monterey, Ventura And Sonoma.
Step-by-step instructions
- Open
System Preferences(gear icon in the Dock or via the Apple menu). - Go to the section
General access. - At the top of the window you will see a field Computer name. Click the button
Change.... - Enter a new name (you can use Cyrillic, but for compatibility, Latin is better).
- Close the window and confirm the changes. A reboot is not required, but you may need to log out.
To check the changes, open Terminal and enter:
scutil --get ComputerName
scutil --get LocalHostName
If you use AirDrop or Screen Sharing, please update as well Local host name in the same settings window. It should be in the format name.local (For example, my-macbook.local).
What if the name doesn't change in Finder?
If the name in the Finder sidebar (under "Network") has not updated after changing it, try:
1. Turn Wi-Fi off and on again.
2. In the Terminal, run sudo killall mDNSResponder.
3. Restart your MacBook.
This will reset the Bonjour cache, which is responsible for displaying devices on the local network.
macOS Features When Changing a Name
Unlike Windows, macOS allows you to use Cyrillic characters in the computer name, but this may cause problems when connecting to it from devices on Windows or LinuxFor example, when trying to access a network folder by name \\MyMacbook You may get an error. In such cases:
- Use Latin for Local host name.
- For network access, use the IP address instead of the name (you can find it in
System Preferences → Network).
⚠️ Attention: If your MacBook connected to a corporate network with a server Open DirectoryChanging your name may disrupt access to resources. Consult your administrator before proceeding.
4. How to change the laptop name in Linux (Ubuntu, Debian, Fedora)
IN Linux-In different distributions, the process depends on the network manager used and the OS version. We will look at a universal method through hostnamectl (relevant for Ubuntu 20.04+, Debian 11+, Fedora), as well as manual editing of configuration files for older systems.
Method 1: Via hostnamectl (recommended)
This is the most reliable method for modern distributions:
- Open
Terminal(Ctrl + Alt + T). - Check your current name:
hostnamectl status - Change the name (replace
new-nameto the desired):sudo hostnamectl set-hostname new-name - Update hosts-file:
sudo nano /etc/hostsFind the line with
127.0.1.1and replace the old name with the new one. Save the changes (Ctrl + O → Enter → Ctrl + X). - Reboot the system:
sudo reboot
After rebooting, check the changes:
hostname
cat /etc/hostname
Method 2: Manual editing (for older versions)
If hostnamectl unavailable (for example, in Ubuntu 18.04), change the name manually:
- Open the file
/etc/hostname:sudo nano /etc/hostname - Delete the old name and enter a new one (one line without spaces).
- Update
/etc/hosts, as described above. - Apply changes without rebooting:
sudo service hostname restartsudo service networking restart
Linux Problems and Their Solutions
IN Linux After changing the name, the following issues may arise:
| Problem | Cause | Solution |
|---|---|---|
| The name is reset after reboot. | Service systemd-hostnamed inactive |
Turn it on: sudo systemctl enable systemd-hostnamed |
| The name is not displayed online. | Not configured avahi-daemon (analogue of Bonjour) |
Install the package: sudo apt install avahi-daemon |
Error while editing /etc/hosts |
Insufficient rights | Use sudo or su |
If you use NetworkManager, after changing the name, restart it:
sudo systemctl restart NetworkManager
5. How to check if the name has changed on a Wi-Fi network
After changing your hostname, it's important to ensure the changes have been applied correctly and are visible on the local network. Here are a few ways to check:
Method 1: Via the command line
In any OS, you can use commands to check the current name:
- 🪟 Windows:
hostnameipconfig /all | find"Host Name" - 🍎 macOS:
scutil --get ComputerNamescutil --get LocalHostName - 🐧 Linux:
hostnamecat /etc/hostname
Method 2: Via a router
Most modern routers display a list of connected devices with their names. To check:
- Open the router's web interface (usually at
192.168.0.1or192.168.1.1). - Log in (default logins/passwords are indicated on the router sticker).
- Find the section
Connected devices,DHCPorLocal area network. - Check if the new name appears next to your laptop's IP address.
If the name has not updated, clear the DHCP cache on the router or reboot it. On some models (e.g., TP-Link or ASUS) there is a button Refresh the list.
Method 3: Via another device on the network
You can check the visibility of your laptop from another computer, phone, or tablet:
- 📱 From Android/iOS: Use apps like Fing or Network Analyzer to scan the network.
- 💻 From another PC:
- IN Windows open
Netin Explorer or runping COMPUTER_NAMEin CMD. - IN macOS/Linux use
ping NAME.localornmap -sn 192.168.1.0/24.
- IN Windows open
⚠️ Attention: If you're using a VPN or proxy, your computer name may not be visible on your local network. Disable them before testing.
6. Common mistakes and how to avoid them
Users often encounter common issues when changing their laptop's Wi-Fi network name. Let's look at the most common ones and how to solve them.
Error 1: Name does not change after reboot
If after all the manipulations the old name continues to be displayed, the reasons may be as follows:
- 🔄 DNS cache: Clean it in Windows (
ipconfig /flushdns) or restart the servicemDNSResponderon macOS. - 📡 Router cache: Reboot your router or find the option in its settings
Clear DHCP Clients. - 🔧 Name conflict: Make sure the new name is unique on your network (use this to check)
nbtstat -a COMPUTER_NAMEin Windows). - 🛡️ Domain Policies: In corporate networks, the name may be managed by the server. Check via
gpresult /r.
Error 2: You cannot enter Cyrillic characters or spaces.
Many users try to use Russian letters or spaces in their computer names, but encounter errors. Hostname formation rules:
- ✅ Allowed: Latin (az, AZ), numbers (0-9), hyphen (
-). - ❌ Prohibited: spaces, Cyrillic, special characters (
!@#$%), underline (_). - 📏 Length: up to 15 characters (on Windows), up to 63 on Linux/macOS (but it is recommended not to exceed 15 for compatibility).
Exception: macOS allows you to use Cyrillic characters in the "Computer Name," but this may cause issues when accessing from Windows/Linux. For cross-platform compatibility, stick to Latin characters.
Error 3: Name resets after system update
Sometimes after major updates (for example, switching from Windows 10 on 11 or updates macOS) the computer name is reset to the default. This happens because:
- 🔄 Reset network settings: The system may perceive the update as a new installation.
- 📜 Profile conflict: In domain networks, the name can be controlled by group policies.
- 🛠️ Migration errors: When updating, not all configuration files are transferred correctly.
To avoid this:
- Before the update lock the current settings (take a screenshot or write down the name).
- After the update check the name and change it again if necessary.
- IN Windows use
PowerShellto force the name to be applied:Rename-Computer -NewName"NAME" -Force
Error 4: Conflict with another device on the network
If two devices on the same network have the same name, this can result in:
- 🚫 Denial of connection to network resources.
- 🔄 Unpredictable behavior when accessed by name (for example, you are connecting to the wrong PC).
- ⚠️ Errors in router or DHCP server logs.
To check for conflicts:
- IN Windows execute:
nbtstat -nand compare
Computer namewith other devices. - IN Linux/macOS scan the network:
nmap -sn 192.168.1.0/24
If a conflict is detected, change the name to something unique or temporarily disconnect the second device from the network.
7. Additional network setup tips
Changing your computer name is just the first step to comfortable work on your local network. Here are a few recommendations to help optimize interaction between devices:
Tip 1: Set up a static IP address
If you frequently access your laptop by name (for example, to access shared folders), assign it a static IP on the network. This will prevent problems when changing the address via DHCP.
How to set up:
- 🪟 Windows:
- Open
Settings → Network & Internet → Wi-Fi → Configure adapter settings. - Right-click on your connection →
Properties→Internet Protocol version 4 (TCP/IPv4). - Select
Use the following IP addressand enter the data (for example,192.168.1.100).
- Open
- Open
System Preferences → Network → Wi-Fi → Advanced. - Tab
TCP/IP→Configure IPv4→Manually.
192.168.1.100 to 192.168.1.200).Tip 2: Turn on network discovery
To make your laptop visible to other devices on the network (for example, for file sharing), enable network discovery:
- 🪟 Windows:
- Open
Control Panel → Network and Internet → Network and Sharing Center. - Select
Change advanced sharing options. - Turn on
Network discoveryAndFile and Printer Sharing.
- Open
- Open
System Preferences → Sharing. - Turn on
File sharingAndScreen sharing(if necessary). - 🐧 Linux: Use Samba for folders:
sudo apt install sambasudo smbpasswd -a user - From another device, run:
ping COMPUTER_NAME.local - If there are no answers, install Avahi (Linux) or Bonjour (Windows).
- 🔒 Do not use personal information in your name (e.g.
Ivan-LaptoporHome PC). - 🛡️ Avoid specifying the model or OS (e.g.
Lenovo-Windows11). - 🔄 Regularly check the list of devices in your router for unknown hosts.
- IN macOS Sometimes it is enough to log out of your account and log back in.
- IN Linux You can apply changes without rebooting by restarting the service
hostname. - IN Windows A reboot is always required.
Tip 3: Use mDNS for local access
Technology Multicast DNS (mDNS) allows you to address devices by name name.local without setting up a DNS server. It is enabled by default in macOS And Linux, but in Windows requires installation Bonjour Services (included in the package) iTunes) or enabling the function LLMNR.
To check if mDNS is working:
Tip 4: Security when changing your name
The hostname may reveal information about your device. To minimize the risks:
8. FAQ: Frequently asked questions about changing the laptop name
❓ Do I need to restart my laptop after changing the name?
Yes, in most cases a reboot is required for changes to take effect at the system and network level. However:
If you do not reboot the device, the new name may not be displayed on the network even if the command hostname shows the current value.
❓ Is it possible to use Cyrillic characters in a computer name?
Technically yes, but it can cause problems:
- 🪟 Windows does not support Cyrillic in the hostname (only Latin, numbers, hyphens).
- 🍎 macOS allows Cyrillic in the "Computer Name", but this may