Offering an unique journey for the customers on your website is a must by today’s web standards. By using Sitecore, you have access to dozens of personalization capabilities that you can use on a properly developed solution.
Below I’m going to show you how to personalize your homepage experience based on the search engine keywords.
Setting up the personalization rule
Adding the personalization rule is quite easy to do. You need to select the component you want to personalize, then you need to click the personalization icon. You can see how it looks like in the picture below:
Next, do the following steps to set up the condition:
- Click on the Plus sign on the top right corner of the page, then you need to give it a name.
- Click on the Edit button and from there, type the search keywords in the search bar.
- Choose the where the search keywords compares to specific value condition, input the word you want to match in the search query and lastly choose the “contains” comparison criteria.
NOTE: You might want to use here the contain criteria because quite often search queries have more than one word but of course you would want the broadest match.
In the image from below you can see the personalization rule I have created:
As a final step, you need to save and publish the component.
Testing the personalization Rule
Well, testing this is a different story. Because usually these rules are setup in a closed environment, you cannot just search for the website name plus the keyword on Google and expect to find it in the results section.
For testing, I personally use a Chrome extension called Referer Control. It’s really neat and it gets the job done.
I will not write here how to use it. I want just to show you the rule that I setup because it’s pretty straightforward:
Once you configure the right referer in the URL, you can then access your website and see if the component that you personalized appears in the page as it should.
But first, it is important to delete any cookies for the website you are testing because that marks the beginning of the session. If any cookies already exists on the website, the test will not work.
In order to check in browser if the search engine is really applied as a referrer, you need to open developer tools, select the loaded page from the Network tab and check in the Referer field from Headers tab if you have the right parameter.
The image from below shows how the field is populated on my side.
What Search Engine Websites are Supported
But if you want to add more websites as a referer, you can add new ones on the following config file from Sitecore:
The section in the file is called: parseReferrer
I hope the information is useful to you and please let me know about any scenarios you want to try with this personalization rule.