{"id":1523,"date":"2017-07-31T17:28:18","date_gmt":"2017-07-31T22:28:18","guid":{"rendered":"http:\/\/montgomeryminds.com\/blog\/?p=1523"},"modified":"2017-07-31T17:28:18","modified_gmt":"2017-07-31T22:28:18","slug":"whats-my-ip-address-from-windows-command-line-cmd-exe","status":"publish","type":"post","link":"https:\/\/montgomeryminds.com\/blog\/whats-my-ip-address-from-windows-command-line-cmd-exe\/","title":{"rendered":"What&#8217;s my ip address&#8211;from Windows command line (cmd.exe)"},"content":{"rendered":"<p><!-- CAN NOT USE TinyMCE aka VISUAL TAB BECAUSE IT REMOVES STYLE TAGS SINCE 3.9 !!!! --><br \/>\n<!-- CAN NOT HAVE ANY BLANK LINES IN STYLE; WP ADDS PARAGRAPH!!! --><br \/>\n<!-- \/cygdrive\/c\/a_no_backup\/dl\/M_M\/usb_drive_copy\/tech\/blog\/__DIR__NAME__HERE__\/post.html --><\/p>\n<style type=\"text\/css\" media=\"all\">@import url(https:\/\/montgomeryminds.com\/css\/wp_blog_fixes.css);<\/style>\n<p>If you&#8217;re behind a router (and most people are) then ipconfig.com will give your LAN address&#8211;local to your building, but not your WAN address&#8211;the IP address that websites see you as.<\/p>\n<p>The most common way to find your WAN IP address is <a href=\"http:\/\/whatsmyip.net\" target=\"_blank\">http:\/\/whatsmyip.net<\/a>.<\/p>\n<p>But that doesn&#8217;t (easily) work from the Windows command line, eg <code>cmd.exe<\/code><\/p>\n<p>But, your salvation is here: Here is something that does. Quite simple:<\/p>\n<pre>\r\nC:\\users\\YOURNAME> nslookup myip.opendns.com. resolver1.opendns.com\r\n<\/pre>\n<p>Notice the dot (&#8220;.&#8221;) after <code>myip.opendns.com<\/code>. That prevents it getting appended.<\/p>\n<hr>\n<p>Reference:<\/p>\n<ul>\n<li><a href=\"https:\/\/superuser.com\/questions\/165986\/windows-command-that-returns-external-ip\">&#8220;Windows command that returns external IP&#8221;<\/a> question at <a href=\"https:\/\/superuser.com\/\">superuser<\/a> &#8211; URL = <a href=\"https:\/\/superuser.com\/questions\/165986\/windows-command-that-returns-external-ip\">https:\/\/superuser.com\/questions\/165986\/windows-command-that-returns-external-ip<\/A>\n<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>If you&#8217;re behind a router (and most people are) then ipconfig.com will give your LAN address&#8211;local to your building, but not your WAN address&#8211;the IP address that websites see you as. The most common way to find your WAN IP &hellip; <a href=\"https:\/\/montgomeryminds.com\/blog\/whats-my-ip-address-from-windows-command-line-cmd-exe\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[3,7],"tags":[],"_links":{"self":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts\/1523"}],"collection":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/comments?post=1523"}],"version-history":[{"count":6,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts\/1523\/revisions"}],"predecessor-version":[{"id":1529,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts\/1523\/revisions\/1529"}],"wp:attachment":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/media?parent=1523"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/categories?post=1523"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/tags?post=1523"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}