如何查找您的 IP 地址
How to find your IP address
如果您知道在哪里查找,那么它既快速又简单。
如果您正在寻找“我的 IP 地址是什么?”的快速答案,一个简单的解决方案是访问 WhatIsMyIP.com 并在那里获取它。但真正的答案有点复杂,因为您的设备不仅仅只有一个 IP 地址。网络上的每台设备都会从路由器获得一个专用设备,而您的整个家庭则共享一个来自互联网提供商的公共设备。公共地址是网站看到的地址,而私有地址仅在您自己的网络内起作用。
你的路由器在两者之间进行转换,这就是手机、笔记本电脑和电视可以同时浏览的方式,同时对外界来说就像一个地址。路由器还通过称为 DHCP 的系统分发私有数据,该系统通常位于路由器本身内部。因此,真正的答案取决于您是在寻找公共地址还是私人地址。
打开浏览器并转到 DuckDuckGo。在搜索栏中输入“我的 IP 是什么”,就可以找到。答案显示在结果的顶部。像 WhatIsMyIP 这样的网站也会做同样的事情,并添加您的大致位置和提供商的名称。
如果您不想使用浏览器,Mac 和 Windows 上都有更快的方法。在 Mac 上打开终端,或在 Windows 上打开命令提示符,键入以下内容并按 Enter:
它只生成您的公共 IP,仅此而已。如果您想要您的私有 IP,请按以下方法操作。
在 Windows 11 上,右键单击任务栏中的网络图标,然后选择网络和 Internet 设置。如果您使用的是 Wi-Fi,请点按“Wi-Fi”,然后点按您所连接的网络。如果您通过以太网连接,请单击“以太网”。向下滚动越过切换开关,直到看到一长串技术细节。大多数名称中都包含 IPv6,您可以忽略它们。查找名为 IPv4 地址的行。它旁边的数字,由点分隔的四组,是您的私有IP。 Windows 10 几乎相同,但在 Wi-Fi 上您可能需要先单击“硬件属性”。
您可以通过打开命令提示符并输入 ipconfig 来执行完全相同的操作。它适用于每个版本的 Windows,并且地址位于活动连接下的 IPv4 地址行。
在 Mac 上,最快的方法是按住 Option 并单击菜单栏中的 Wi-Fi 图标。您的 IP 地址以及路由器的 IP 地址都列在那里。较长的方式也适用于有线连接:Apple 菜单 > 系统设置 > 网络。然后选择您的连接,单击“详细信息”,然后查看“TCP/IP”选项卡。
在 iPhone 上,转到“设置”,点击 Wi-Fi,然后点击网络旁边的 i 并向下滚动到 IP 地址。 Android 在许多手机上的工作方式相同:打开“设置”,点击 Wi-Fi,然后点击网络旁边的 i 或齿轮图标并查找 IPv4。在 Pixel 上,路径为“设置”>“网络和互联网”>“互联网”>“齿轮图标”>“网络详细信息”。制造商会不断调整产品,因此您的手机可能会略有不同。
路由器有自己的地址,您可以在浏览器中输入该地址来访问其设置页面。您的设备将其列为默认网关(或只是路由器),通常为 192.168.1.1、192.168.0.1 或 10.0.0.1。在 Windows 上,它位于 ipconfig 输出中。
主要用于故障排除。如果您的连接缓慢或中断,并且重新启动也没有帮助,您的提供商可能会要求您提供设备的 IP,以确定问题是在您这边还是他们那边。当您设置打印机、游戏服务器或远程访问家里的机器时,它也会出现。
您的公共 IP 可能不会保持不变。大多数家庭连接使用动态地址,当您重新启动调制解调器或路由器时,该地址可能会发生变化。静态的存在,但它们主要用于服务器,例如托管大型网站或运行电子邮件的服务器。
一个常见的问题是你是否可以查找别人的IP。答案是否定的,不是从你的角度来看。互联网上的随机人无法看到您的IP,而公共IP通常指向整个网络,而不是一个人或设备。不过,网站和广告商可以看到它,有时还可以用它来构建您喜欢的图片。 VPN 会向他们隐藏数据,代理也会这样做,有些代理不会加密您的流量,而 VPN 总是会加密。如果您想尝试一下,可以查看本指南,了解如何使用 VPN。
原文(English)
It's quick and easy, if you know where to look.
If you're looking for a quick answer to "What is my IP address?", a simple solution is to go to WhatIsMyIP.com and get it there. But the real answer is a little more complicated, because your devices don't have just one IP address. Every device on your network gets a private one from your router, and your whole home shares a single public one from your internet provider. The public address is the one websites see, while the private one only matters inside your own network.
Your router does the translating between the two, which is how a phone, a laptop and a TV can all browse at once while looking like a single address to the outside world. The router also hands out the private ones through a system called DHCP that usually lives inside the router itself. So the real answer depends on whether you're looking for your public address or one of your private ones.
Open a browser and go to DuckDuckGo. Type "what is my IP" into the search bar, and there it is. The answer shows up at the top of the results. Sites like WhatIsMyIP do the same thing and add your approximate location and your provider's name.
If you'd rather stay out of the browser, there's a faster way on both Mac and Windows. Open Terminal on a Mac, or Command Prompt on Windows, type the following and press Enter:
It produces your public IP and nothing else. If you're after your private IP instead, here's how.
On Windows 11, right-click the network icon in the taskbar and choose Network and Internet settings. If you are on Wi-Fi, click Wi-Fi, then click the network you're connected to. If you are connected through Ethernet, click Ethernet instead. Scroll down past the toggles until you reach a long list of technical details. Most of them have IPv6 in the name, and you can ignore those. Look for the line called IPv4 address. The numbers next to it, four groups separated by dots, are your private IP. Windows 10 is nearly the same, though on Wi-Fi you may need to click Hardware properties first.
You can do the exact same thing by opening Command Prompt and typing ipconfig. It works on every version of Windows, and the address is on the IPv4 Address line under your active connection.
On a Mac, the quickest route is to hold down Option and click the Wi-Fi icon in the menu bar. Your IP address is listed there, along with your router's. The longer way works for wired connections too: Apple menu > System Settings > Network. Then pick your connection, click Details, and look under the TCP/IP tab.
On an iPhone, go to Settings, tap Wi-Fi, then tap the i next to your network and scroll down to the IP address. Android works the same way on many phones: open Settings, tap Wi-Fi, then tap the i or the gear icon next to your network and look for IPv4. On a Pixel, the path is Settings > Network & internet > Internet > gear icon > Network details. Manufacturers move things around, so your phone may differ a little.
The router has its own address, and it's the one you type into a browser to reach its settings page. Your device lists it as the Default Gateway (or just Router), and it's often 192.168.1.1, 192.168.0.1 or 10.0.0.1. On Windows, it's right there in the ipconfig output.
Mostly for troubleshooting. If your connection is laggy or dead and a restart didn't help, your provider may ask for your device's IP to work out whether the problem is on your end or theirs. It also comes up when you're setting up a printer, a game server or remote access to a machine at home.
Your public IP probably won't stay put. Most home connections use dynamic addresses, which can change when you restart your modem or router. Static ones exist, but they're mostly for servers, such as the ones hosting big websites or running email.
A common question is whether you can look up someone else's IP. The answer is no, not from your end. Random people on the internet can't see yours, and a public IP usually points to a whole network, not one person or device. Websites and advertisers can see it, though, and sometimes use it to build a picture of what you like. A VPN hides it from them, and a proxy does too, some proxies do not encrypt your traffic, and a VPN always does. If you want to try one, you can check out this guide on how to use a VPN.
本文为自动翻译,可能存在偏差,请以原文为准。发布于 2026-11-16 04:30
阅读原文 ↗https://www.engadget.com/2313878/how-to-find-ip-address/