By continuing to use our website, you consent to the use of cookies. Please refer our cookie policy for more details.

    How to integrate Yotpo & Shopify?

    Yotpo is an official Shopify partner with over a thousand reviews in the Shopify app store. By connecting Yotpo to your Shopify store, it’s not only possible to facilitate customer reviews, but also carry out visual marketing, loyalty programs, and referrals to increase conversion, drive traffic, and build trust.

    For example, our customer’s website uses Yotpo for reviews. When someone leaves a product review on the website, they are sent a verification email by Yotpo. These emails sent by Yotpo for verifying product reviews, redirect users to a Yotpo landing page. This hampers the user experience and results in users not verifying their reviews.

    Grazitti resolved this challenge by doing the following:

    • Contacted Yotpo’s Support team to provide us with a customized landing page URL. We then created a script through Javascript which reads the parameters in the URL and populates the content on the page accordingly in iFrame.
    • For example, suppose the link that they provided was The link came with dynamic parameters and looked like this –
    • For the query parameters, the encoded page URL parameter is
    • The iFrame URL must then include the decoded page_url parameter first, and all additional parameters afterwards, and should look like this:
    <iframe src=”

    Here is how you can implement it –

    1. From your Shopify Admin go to the Online Store

    2. Then click on ‘Pages’ on the left side

    3. Now click on ‘Add Page’

    4. In the content section, click on Show HTML

    5. Copy and paste following code

    div#targetDiv {margin: auto;text-align: center;}
    .feature_divider, h1 { display: none;}
    .store-logo{display:none;}iframe {  min-width: 320px;  }
    @media screen and (max-width:420px) { {line-height: 27px;} {line-height: 27px;}

    /* Use default jquery file, if required */

    <script src=""></script>
    function $_GET(param) {
    	var vars = {};
    	window.location.href.replace( location.hash, '' ).replace( 
    		/[?&]+([^=&]+)=?([^&]*)?/gi, // regexp
    		function( m, key, value ) { // callback
    			vars[key] = value !== undefined ? value : '';
    	if ( param ) {
    		return vars[param] ? vars[param] : null;	
    	return vars;
    var page_url = $_GET('page_url');//
    var deco_var = decodeURIComponent(page_url );
    var getParams = function (url) {
    	var params = {};
    	var parser = document.createElement('a');
    	parser.href = url;
    	var query =;
    	var vars = query.split('&');
    	for (var i = 0; i < vars.length; i++) {
    		var pair = vars[i].split('=');
    		params[pair[0]] = decodeURIComponent(pair[1]);
    	return params;
    var current_url_array = [];
    current_url_array = getParams(window.location.href);
    var newPathname = "";
       $.each(current_url_array, function (key, val) {
    	  if(key == 'page_url'){
    		return true;	
    	newPathname += key+"="+val;
    	newPathname += "&";
    if(deco_var .includes('?')){
    var new_parameter_url = deco_var +"&"+ newPathname;
    } else {
    var new_parameter_url = deco_var +"?"+ newPathname;
     var lastChar = new_parameter_url .slice(-1);
     if (lastChar == '&') {
      strVal = new_parameter_url .slice(0, -1);
    function addIframe() {
    var target = document.getElementById("targetDiv");
    var makeIframe = document.createElement("iframe");
    makeIframe.setAttribute("src", strVal );
    makeIframe.setAttribute("scrolling", "no"); = "430px"; = "100%"; = "none";
    <div id="targetDiv"></div>
    <script type="text/javascript">
    // <![CDATA[
    // ]]>

    6. Click on ‘Save’ and you’re done!

    Please note that the parameters shown here will not necessarily apply for your account and may vary according to the email type and other features in use.