f Other Rules (Javascript, Cookie, Meta Tags, and more)
Understanding Sumo Display Rules
By default your Sumo apps will display on all pages, but you can use Display Rules to determine where various Sumo Apps will display on your site. The behavior of a Sumo app is split between Show and Don't Show rules. These rules can be set independently of one another, or set in conjunction with another to create more advanced conditional rules.
Setting up Show rules will configure your Sumo apps to display only when the conditions set in your display rules are met.
Setting up Don't Show rules will configure your Sumo apps to display on all pages except when the conditions set in your Don't Show rules have been met.
Setting up both Show and Don't Show rules configures your apps to display both when the conditions in your Show rules are met, and not display when the conditions in your Don't show rules are met.
Note: Don't Show rules will always take precedence if there is a conflict between Show and Don't Show rules.
Setting Up Display Rules
List Builder
1 To set up Display Rules in List Builder, open up a Form you want to set Display Rules for and click on the Visibility tab. (Make sure Manual mode is enabled in the Visibility tab.)
2 Click Add New Rule to create a Display Rule (for this Form only). Display Rule "sets" can be saved and loaded from here as well, if you wanted to use the same set of Rules on different Forms.
Other Sumo Apps
Aside from List Builder, all other Sumo apps' Display Rules can be configured as well.
1 For example, to find Display Rules in the Share app, open up the app and find the Display Rules tab at the top of the window.
2 Next, click Add New Rule to create a new Display Rule.
Adding To Rules
It is important to note that Display Rules can be used in combination with another to create more advanced, conditional rules. When you have 2 separate Display Rules, they don't work together since they are working as Rule A OR Rule B. As an example, if you add 2 separate rules on your form that say:
"Show on URLs containing blog"
"Show on Desktop devices"
Those rules will work as either "show the form on URLs containing blog OR show on desktop devices". If you want those rules to BOTH apply to the form as 1 overall rule, you would want to create the first rule and then add the second rule to the first rule. In this case, the rules will work as "show on URLs containing blog IF the user is on a desktop device".
1 This can be done by clicking the "+" next to any rule.
2 Next, select the rule you would like nested within the first.
3 The result will look like the following, and the result will be a form that displays on the Homepage IF the visitor is viewing on a desktop device.
Live Example of Nested Display Rules
Display Rule Types & Descriptions
URL Display Rules
Paths | |
Options | Exactly Matching | Beginning With | Containing |
Example | |
Explanation | This rule will show your form for exact URL matches (https://mysite.com/page1), sites beginning with a URL (https://mysite.com/blog), or pages containing a word, phrase, or slug (/blog, /categories, /shirts). This rule will show the app/form only on pages beginning with /blog. |
With A Query Parameter | |
Options | Exists | Does Not Exist | Is Equal To | Does Not Equal | Contains | Does Not Contain |
Example | |
Explanation | The rule will show the app/form only when the visitor's URL has utm_campaign=facebook in it. |
With A Hash | |
Options | Exactly Matching | Beginning With | Containing |
Example | |
Explanation | This rule will show the app/form only when the visitor's URL has #sumolife in it. |
Page Type Rules
Homepage | |
Example | |
Explanation | This rule will show the app/form only on your home page. |
Article Pages | |
Example | |
Explanation | This rule will show the app/form only on pages that Sumo detects an article on. |
Device Rules
With Sizes | |
Options | Bigger Than | Smaller Than |
Example | |
Explanation | This rule will show whenever the browser width is less than or greater than the specified pixel amount. |
OS | |
Options | Android | iOS | Windows Phone/Mobile | Mac | Ubuntu | Windows |
Example | |
Explanation | This rule will show the app/form only on devices using the specified Operating System. |
Browser | |
Options | Chrome | Firefox | Internet Explorer | Opera | Safari |
Example | |
Explanation | This rule will show the app/form only on devices using the specified Browser. |
IP Address | |
Example | |
Explanation | This rule will show the app/form only when visitors with the specified IP address are viewing your site. |
Referrer Rules
Referrer Domain Names | |
Options | Exactly Matching | Begins With | Containing | Matching [SERVICE] |
Example | |
Explanation | This rule will show the app/form only when the visitor is coming from a Google.com referrer domain. |
Referrer URLs | |
Options | Exactly Matching | Begins With | Containing | Matching [SERVICE] |
Example | |
Explanation | This rule will show the app/form only when the visitor is coming from a specific URL. |
Visitor Behavior Rules
Visitor's First Page View | |
Example | |
Explanation | This rule will show the app/form only when the visitor is on their session's first page view on your website. |
Visitors Page Views | |
Options | Fewer Than | Exactly | Greater Than |
Example | |
Explanation | This rule will show the app/form only when the visitor has visited at least 3 pages on your site during a given session. |
Location | |
Options | Country | State | City |
Example | |
Explanation | This rule will show the app/form only when the visitor's IP address is from the United States. |
Date | |
Options | Before / After | [DATE] | [TIME] | [TIMEZONE] |
Example | |
Explanation | This rule will show the app/form only after 12:00 AM CST on November 9, 2017. |
Other Rules
Cart Total | |
Options | Less Than | Less Than Or Equal To | Greater Than | Greater Than Or Equal To |
Example | |
Explanation | This rule will show the app/form only for visitors with the designated cart total (Shopify only) |
Cart | |
Example | |
Explanation | This rule will show the app/form only for visitors with carts that contain an item with designated product_id, sku, etc. (Shopify Only) |
User Agents | |
Options | Exactly Matching | Begins With | Containing |
Example | |
Explanation | This rule will show the app/form only for visitors with "Mozilla" in their browser's User Agent string. |
Meta Tag | |
Options | [AttributeName] | Starts With / Equal To / Not Equal To / Contains / Does Not Contain | [AttributeValue] |
Example | |
Explanation | This rule will show the app/form only on pages where the following meta tag is present: |
Cookie Named | |
Options | [CookieName] | Exists / Doesn't Exist / Equal To / Not Equal To / Contains / Doesn't Contain | [CookieValue] |
Example | |
Explanation | This rule will show the app/form only on pages where the visitor has a cookie set in their browser named loggedIn with a value of true. |
Javascript | |
Options | [Variable/Function] | Exists / Doesn't Exist / Equal To / Not Equal To / Less Than / Greater Than / Custom |
Example | |
Explanation | This rule will show the app/form only on pages where the visitor has a JavaScript variable set in their browser named isUser with a value of true (in order for Sumo to detect variables, attach the variable to the window object (i.e. window.variableName)). |