Skip to main content

Using server-side JavaScript in Sitecore Personalize


Describes using server-side JavaScript in the Sitecore Personalize application.

You can use a real-time audience to enable your organization to use a guest's real-time session behavior to determine whether to run an experiment. Sitecore Personalize can run server-side JavaScript when the real-time audience is generated.

For example, you might want to show a loan offer to guests who are actively searching on your site for loans. To do this, you can apply an audience template to the experiment that checks in real-time to see what a guest has historically searched for, while also taking into account the pages of your organization's website that they are currently visiting, such as the loan types informational page. You can set your experiment to only display if they are currently visiting the loan types informational page but have also searched in the past for personal loans.

You do not have to be familiar with JavaScript to apply server-side JavaScript when creating an experiment. You can use an audience template to do this, which is essentially a saved real-time audience. Sitecore Personalize can run server-side JavaScript whether the real-time audience was built from an audience template or was created as a once-off for an experiment.