Like HowStuffWorks on Facebook!

How Pop-up Blockers Work

Pop-up Blocker Software
A typical pop-up ad
A typical pop-up ad

Most pop-up ads are programmed in the Javascript programming language. When you click on a Web page that has pop-up ads, the ads activate as the page loads into your browser. The code for the pop-ups can be found within the code for the page itself. Pop-up blockers are programmed to scan a Web page's source code and search for any signs of a program telling your browser to open a new window. If the blocker finds this code, it deactivates the command and you don't get any pop-ups.

Not all pop-ups open when the Web page loads, though. Some activate when you click on a link or when you scroll your mouse over an activation site on the Web page. A good pop-up blocker can detect the code for these ads as well, though some are only able to deactivate a pop-up after it starts to open. If you've ever seen a pop-up quickly appear and disappear when you have a pop-up blocker activated, that's what happened. The blocker detected the ad after it activated, then disabled it.

Some pop-ups use other programming languages, such as Flash. A Javascript pop-up blocker is helpless against flash pop-ups because it's a completely different programming language. To block Flash ads, you'll need Flashblock program. These programs are similar to pop-up blockers in that they disable the commands found in Web pages that activate Flash animation. You can find programs that incorporate Javascript and flash ad blockers in one package.

But not all pop-up blockers are created equal. Some of them are very good at blocking nuisance pop-ups while leaving helpful pop-ups alone -- they're Intelligent pop-up blockers. In general, most intelligent pop-up blockers only disable pop-ups that open when a Web page first loads into your browser -- any pop-up that opens as a result of the user clicking on a link remains unhampered.

Trainable pop-up blockers rely on user input to determine which pop-ups to deactivate and which to leave alone. No two pop-up blocking programs are exactly alike, but in general the blocker asks the user if he wants to disable a particular pop-up when it first appears on the user's screen. If the user clicks on "Yes," then the blocker puts the offending pop-up on a black list, or a list of ads that should be deactivated in the future.

If you choose "No," the blocker puts the pop-up on a white list, which means it won't attempt to block the pop-up window again. While this kind of blocker is very easy to customize, it can become frustrating for the user as he makes choices for each and every pop-up. Also, if the advertiser alters the original pop-up in some way, it may slip past the blocker.

Serial pop-up blockers block every pop-up ad they're capable of uncovering. These blockers seek out every variation of the code used to generate pop-up ads and deactivate it whether the pop-up contains advertising or not. While these blockers usually ensure the user a pop-up-free experience, they can also cause complications when navigating through certain Web pages.

In the next section, we'll look at why you would want to disable a pop-up blocker.