Best Windows 10 commands to fix PC internet

All the commands in the article require you to do them through the Windows 10 Command Prompt.

To access the Command Prompt, click the Start button, type in the command cmd and Enter.

The commands below are usable in earlier versions of Windows (Windows 7) and their usage is identical. However, in this article, I will focus on Windows 10.


When connecting to a website, you enter a text URL, such as https://www.google.com.

However, when your browser connects to the hostname, www.google.com, it must first convert it to an IP address by querying your configured DNS servers.

If your DNS server doesn’t work or returns wrong information, your computer won’t be able to connect to websites. To diagnose these problems, you can use commands. nslookup to convert domain to IP address.

For example, if you want to see the IP addresses associated with www.google.com, enter the command nslookup www.google.com, as shown below.

When using nslookup, the command returns both IPv4 and IPv6 addresses. Here I am only interested in IPv4 addresses.

If your current DNS servers are not responding or returning IP addresses to websites, your network problems may be DNS related.

To fix this problem, try different DNS servers, such as Google and Cloudflare DNS servers, and see if they resolve your issue.

For the fastest DNS changes and available options, you can use DNS Jumper.


The ping command allows you to test if you can connect to a hostname or IP address and provides a basic measurement of the latency between your connection and the remote device.

To use the ping command, just open a command prompt and type ping [tên máy chủ] or ping [địa chỉ ip] then press Enter.

For example, to check if you can connect to www.google.com, you type ping www.google.com and press Enter.


As you can see from the above screenshot, we pinged to www.google.com, we got four responses from its IP address

Each of these answers has a round-trip time from 20ms, which is not very fast because I am using Wi-Fi and a bit far from the router, if plugged in, this number can be reduced.

However, if you start seeing ping response times in the hundreds, this indicates a poor connection between you and the site.

Also, the pings show that we sent four packages and got all 4 back, with 0% lost. If you start seeing packet loss (now Request timed out), it’s a connection problem.

Finally, if you use the ping command and it shows Destination host unreachable, but other computers have no problem connecting to your network, then you have network connectivity problems on your computer.


When you connect to a remote device, your requests travel through a series of different routers called hops before they reach their final destination.

If you find that your connection to a remote server is slow, you can use the tracert command to check which router is slow.

When using the Windows tracert command, you will see each connection your request will go through before it reaches its final destination.

For each connection, tracert will show three response times so you can see the speed of that particular connection.

For example: you can use the tracert www.google.com command to see the connections your request goes through before reaching Google’s web server.

The fewer hops and lower the response time, the faster your connection.


However, everything here seems to be for reference only, routing congestion is usually not something you can actively fix and you will need to wait until there is less traffic or problems Routing is fixed by the ISP provider.

One tip is that you can use a VPN so that you can route through another route.


The PathPing command is an interesting utility because it combines both the ping and tracert commands into one tool.

Using this tool you can check the route your request takes when connecting to a remote device and do a ping to each router to check if the device is reachable or not. no and how slow its response.

To use the command, you would enter pathping www.google.com from the command prompt, as shown below.


The pathping command will take longer to complete than using the ping and tracert commands alone.


If your Internet seems to be working properly, but you are having trouble connecting to a particular website or service, you can use the Telnet command to check if the service is running on the server. remote or not.

The telnet command is a utility that enables two-way communication between your computer and a remote device. Originally designed for remote console access to a server, Telnet can also be used to diagnose if you can connect to a specific service running on the hostname.

When a server is running on a remote computer, it will “listen” on certain TCP ports that you can Telnet to and see if you can connect to the service.

Some of the more common ports that you will test with Telnet are:

  • FTP: port 21
  • SSH: port 22
  • HTTP: port 80
  • HTTPS: port 443

For example, if you want to check if the web server is listening on www.google.com, you can use the command telnet www.google.com 443 to connect to the web server on port 443.

If a service is not running on TCP port 443, Telnet will say, “Connecting To www.google.com…Could not open connection to the host, on port 443: Connect failed“.

However, if the service is running, you will see a blinking pointer indicating a connection.

Best Windows 10 commands to fix PC internet

In case you run and get the message below, it means that telnet is not installed on your machine.

Best Windows 10 commands to fix PC internet

To install telnet follow these steps:

Step 1: Make sure the Hyper-V feature is installed by pressing Windows + WILL to open the search window, type in Turn Windows features on or off, run this.

How to install virtual machine on Windows 10 without VMWare, Virtualbox

Find item Telnet Client, tick then sau OK. Restart your device to enable this feature.

Best Windows 10 commands to fix PC internet

How to fix your network connection

After using these commands, you find that your Internet connection is not working or slow, it is difficult to determine the cause.

To troubleshoot connectivity issues, Microsoft recommends the following steps:

  1. Use the Network troubleshooter by clicking Start > Settings > Network & Internet > Status. In Change your network settings, you’ll choose Network troubleshooter. Run through the troubleshooting wizard to see if Windows 10 can automatically resolve any detected issues.
  2. If you are using WiFi, make sure you are connected by going to Start > Settings > Network & Internet > WIFI. Next, choose Show available networks and if the network you want to view appears in the list, select it, then select Connect.
  3. If you are using a wired network (Ethernet), make sure that your cable is properly plugged into the computer and that there is no problem with the router. You can also try swapping the cable, if possible, to make sure it’s not loose cable ends or other physical issues causing the problem.
  4. Test your Internet connection by accessing websites from another device. If you are able to connect from other devices, the problem may be only on this computer. However, if no one can access the Internet, possibly because of the router or Internet modem, you should reboot.
  5. You can also try changing the DNS server as described above, disconnecting from the VPN or doing a SpeedTest to make sure your ISP connection is not the problem.

The above are command line internet troubleshooting, if you still cannot connect to the Internet or speed tests show a very low number you should contact your ISP and ask for their help you fix the problem.

An Nhiên

Related Posts