# How does Pi-hole work?

**URL:** <https://discourse.pi-hole.net/t/how-does-pi-hole-work/3141>\
**Category:** FAQs\
**Created:** [May 14, 2017, 3:39am UTC](https://discourse.pi-hole.net/t/how-does-pi-hole-work/3141 "2017-05-14T03:39:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jacob.salmela](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/jacob.salmela/32/8_2.png) [@jacob.salmela](https://discourse.pi-hole.net/u/jacob.salmela)\
**Post date:** [May 14, 2017, 3:39am UTC](https://discourse.pi-hole.net/t/how-does-pi-hole-work/3141/1 "2017-05-14T03:39:48Z")

</div>

To understand how Pi-hole works, it's helpful to have a basic understanding of what happens when you visit a Website in your browser. But in a sentence:

> **Pi-hole intercepts requests for advertisements and prevents them from being downloaded**

# About this FAQ

This article is meant to be a **high-level document** that attempts to avoid as much technical jargon as possible.

* * *

To keep things simple, I will describe a basic task, like visiting a Website. Using those same steps, I will:

1. describe what happens _normally_
2. describe how a _traditional ad blocker_ (like Ad Block Plus) modifies this normal behavior
3. describe how _Pi-hole_ modifies this normal behavior
4. contract how Pi-hole _differs_ from traditional ad blockers

# What normally happens when you visit a Website

When you want to visit a Website, you would:

1. open a Web browser
2. type macworld.com (or some other Website) into the address bar
3. press Enter
4. watch the Webpage load on your screen
5. watch the advertisements load as well

# What is happening when these steps are taking place?

1. open a Web browser

- **not much happens here; it's just your interface for accessing Webpages**

1. type macworld.com into the address bar
2. press Enter

- **the query _macworld.com_ is sent to a server to find out where it is located**
- **think of it like like a phone book--computers understand numbers, not words, so a server needs to look up what number belongs to macworld.com and then tells your computer where to find it**

1. watch the Webpage load on your screen

- **now that your computer knows where the server is, it begins downloading the Webpage**

1. watch the advertisements load as well

- **most Websites are complex and actually load files, images, and videos from other places**
- **so even though you only wanted to visit _macworld.com_, in the background, your computer is also asking a server where to find other domains like doubleclick.com, b.scorecardresearch.com, or images.techhive.com**
- **often, these other domains are services used to display ads when you visit the webpage**
- **so when you visit macworld.com, your computer is actually also visiting several other domains and downloading information from all of them**

# How does a traditional ad blocker block these ads?

Using the same steps, I have included information on how traditional ad blockers work

1. open a Web browser
2. type macworld.com into the address bar
3. press Enter
4. watch the Webpage load on your screen

- **your computer will still download macworld.com, as well as the other domains mentioned previously**

1. ~~watch the advertisements load as well~~

- **even though the ads were downloaded, the browser plugin will just hide these from your view**

# How does Pi-hole block these ads?
1. open a Web browser 2. type macworld.com into the address bar 3. press Enter - \*\*Pi-hole looks up macworld.com and begins downloading it, but it will detect the domains used to serve advertisements and instead of looking up the real address of those sites, it will send a fake address instead\*\* - \*\*this allows the \_legitimate\_ content on macworld.com to load, but \_prevents\_ the ad images and videos from being downloaded\*\* - \*\*this is a \_critical\_ difference between Pi-hole and traditional ad blockers because Pi-hole will prevent the ads from being downloaded in the first place (making the Webpage [load faster](https://discourse.pi-hole.net/t/will-pi-hole-slow-down-my-network/2048)).\*\* 4. watch the Webpage load on your screen - \*\*your computer will still download macworld.com, but \_not\_ any domains that appear on the blocklist\*\* 5. ~~watch the advertisements load as well~~ - \*\*since the ads were not downloaded in the first place, they do not need to be hidden from your view since they do not exist in the first place\*\*
