How to block users?

You can create as many block instances as needed. They work as a normal post or page, you can set them to draft, publish, schedule or send it to trash. Each block instance is based on 3 things:

  • Title: Just give a name to your redirection
  • Block rules: Here we define a set of rules that will determine if the user will be blocked or not.
  • Block options: The different settings and blocking message to display to the user

Block rules

Geo Blocker

On this section you can combine multiple rules between each other and is the most powerful part. You can create group of rules using AND or OR buttons.

For example on the screenshot above the block will be performed only if the user is located in the test page, and his country is US. If those two statements are true the redirection will be performed.

That rule for example could be extended with an OR group of other rules and say for example redirect if the user is from Canada. So either the user is from Canada OR the two rules above match, the block will be performed.

You need to be careful to not overlap rules. For example if you do the following to block all user from US except the ones that are in contact page and you do the following:

rule 1

On the example above if the user is from US and he is on the Contact page will be blocked because rule group #2 overwrite rule group #1. Instead you need to add both rules using the AND button:

rule 2

It's important to add geo rules as the last rule of each group. That way is a prior rule fails, the geo rule won't run and you will save requests

A useful tip to keep in mind when geotargeting by zip codes is that we can use the * as a placeholder to replace a series of numbers. As we see in the following example 72*, equals all zip codes beginning with 72, such as 72345 or 72134.

zip-codes blocker

You can also create Global Rules, this rules will apply before the regular Rules, and it will apply with each Rule as if was followed by an AND. For example:

global block rules

In the image above the rules will apply in the following order:

The users will be blocked IF the page type is EQUAL to Post AND the country is EQUAL to United States

OR

The users will be blocked IF the page type is EQUAL to Post AND the country is EQUAL to Canada

OR

The users will be blocked IF the page type is EQUAL to Post AND the country is EQUAL to France

Check our blog tutorial to learn how to block users by country. We will show a real example on to use this addon.

Block Options

block options

On this section you find the different options for this block:

  • Message: The message that will be displayed to the user being block. You can use HTML or shortcodes in here.
  • Exclude Search engines: By default you don't want to redirect search engines, and just do it to user.
  • Ip whitelist: You can add as many IPs as needed to be excluded from the redirection.

Check out our WordPress geolocation solutions
to find out everything you can do!

Start your free trial