# How do websites know where I live?

**URL:** <https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715>\
**Category:** Factual Questions\
**Created:** [November 18, 2005, 9:42pm UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715 "2005-11-18T21:42:47Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jackknifed\_Juggernaut](https://avatars.discourse-cdn.com/v4/letter/j/9de053/32.png) [@Jackknifed\_Juggernaut](https://boards.straightdope.com/u/Jackknifed_Juggernaut)\
**Post date:** [November 18, 2005, 9:42pm UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/1 "2005-11-18T21:42:47Z")

</div>

They seem to know my city. How else would I get a pop-up that says: “\<My city\> girls want to meet you” Does my computer broadcast information about me? Could my high-speed provider be giving a signal?

---

<div class="post-metadata">

**Author:** ![What\_Exit](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/what_exit/32/10652_2.png) [@What\_Exit](https://boards.straightdope.com/u/What_Exit)\
**Post date:** [November 18, 2005, 9:44pm UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/2 "2005-11-18T21:44:17Z")

</div>

TRACERT command and a reverse lookup on the server will locate you close to your town. I am sure there are other methods but this is an old one.

Jim

---

<div class="post-metadata">

**Author:** ![Shagnasty](https://avatars.discourse-cdn.com/v4/letter/s/9dc877/32.png) [@Shagnasty](https://boards.straightdope.com/u/Shagnasty)\
**Post date:** [November 18, 2005, 9:50pm UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/3 "2005-11-18T21:50:32Z")

</div>

IP addresses are roughly translatable into cities and towns. It will usually get you very close. There is a website that lets you input an IP address and it tells you where it is. That can be useful for lots of reasons. One scary thing is that websites usually log visiting IP addresses. You can go through those and cross-reference them with cities, towns, and countries. I have my own website with personal photos and information. I did an x-ref before and was very suprised to find very frequent traffic from places where I only know one person and they aren’t really close friends or family.

---

<div class="post-metadata">

**Author:** ![garius](https://avatars.discourse-cdn.com/v4/letter/g/e19b73/32.png) [@garius](https://boards.straightdope.com/u/garius)\
**Post date:** [November 19, 2005, 1:03am UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/4 "2005-11-19T01:03:06Z")

</div>

As mentioned - most likely by IP Address.

Whilst it’s used most obviously for advertising purposes, there are some other uses - i’ve just finished building a website for a magazine, for example, that has both a US version and a UK version.

IP relocation allows me to have one site for both, but with the content tweaked according to region, without users in either country realising.

---

<div class="post-metadata">

**Author:** ![aeropl](https://avatars.discourse-cdn.com/v4/letter/a/f05b48/32.png) [@aeropl](https://boards.straightdope.com/u/aeropl)\
**Post date:** [November 19, 2005, 2:12am UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/5 "2005-11-19T02:12:14Z")

</div>

Can you use this somehow to find all websites hosted that are locally?

---

<div class="post-metadata">

**Author:** ![Shagnasty](https://avatars.discourse-cdn.com/v4/letter/s/9dc877/32.png) [@Shagnasty](https://boards.straightdope.com/u/Shagnasty)\
**Post date:** [November 19, 2005, 2:22am UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/6 "2005-11-19T02:22:07Z")

</div>

> [@aeropl](#):
>
> Can you use this somehow to find all websites hosted that are locally?

You could locate IP address based in a certain range. You would have to know the ranges that were local though. I also have no idea how to scan all IP addresses by range to find sites.

However, the biggest problem is that most people pay some company far, far away to host their web site. I think mine is hosted in California and I live in Massachusetts.

---

<div class="post-metadata">

**Author:** ![Fear\_Itself](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/fear_itself/32/19637_2.png) [@Fear\_Itself](https://boards.straightdope.com/u/Fear_Itself)\
**Post date:** [November 19, 2005, 2:26am UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/7 "2005-11-19T02:26:17Z")

</div>

[Here is an IP Locator](http://www.geobutton.com/IpLocator.htm) that will display what city is associated with your IP address.

---

<div class="post-metadata">

**Author:** ![FlyingRamenMonster](https://avatars.discourse-cdn.com/v4/letter/f/ce7236/32.png) [@FlyingRamenMonster](https://boards.straightdope.com/u/FlyingRamenMonster)\
**Post date:** [November 19, 2005, 5:59am UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/8 "2005-11-19T05:59:39Z")

</div>

Oh and IP doesn’t always show where you live. Websites think I live in Sydney, for example.

---

<div class="post-metadata">

**Author:** ![Southessex](https://avatars.discourse-cdn.com/v4/letter/s/a3d4f5/32.png) [@Southessex](https://boards.straightdope.com/u/Southessex)\
**Post date:** [November 19, 2005, 10:24am UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/9 "2005-11-19T10:24:43Z")

</div>

> [@aeropl](#):
>
> Can you use this somehow to find all websites hosted that are locally?

Define “local”. As **Shagnasty** said, a site can be about one place, yet be located in another place. My website has reviews of restaurants and whatnot in the Charlotte area, yet is hosted in Houston. You can even get to my site via a .co.uk extension, and I think Houston is about as opposite from the UK as you can get.

Of course, you could always use IP ranges to check sites that are, in fact, hosted locally… but they might not be all that interesting.

And IP locations don’t always work. Some ISPs - like AOL - might have all their IPs registered in one location (Dulles, Virginia… isn’t that where their headquarters are?), yet their users are in other locations. In some situations, geographic IPs simply don’t work at all, as **csharpmajor** seems to have found out.

---

<div class="post-metadata">

**Author:** ![Paul\_in\_Qatar](https://avatars.discourse-cdn.com/v4/letter/p/ccd318/32.png) [@Paul\_in\_Qatar](https://boards.straightdope.com/u/Paul_in_Qatar)\
**Post date:** [November 19, 2005, 11:47am UTC](https://boards.straightdope.com/t/how-do-websites-know-where-i-live/331715/10 "2005-11-19T11:47:28Z")

</div>

My IP pops through Kuwait. I get “Sexy Kuwait Girls Want to Meet You.” Unlikely at best I think.
