Nelio A/B Testing is a plugin specifically designed for WordPress. Its aim is to make A/B Testing in WordPress extremely easy. However, this entails some limitations: as soon as one of your visitors leaves WordPress and accesses an external page, Nelio A/B Testing can no longer track her activity.
Even though usually this is not a problem as all events tend to occur in WordPress, there are some scenarios in which the conversion occurs outside. One typical example is an e-commerce system, where the checkout process is performed outside WordPress. Let’s see a couple of workarounds.
Method 1. Using “External Page” Conversion Actions
If you’re interested in tracking the fact that a user visited an external page, the easiest way to do so is by using External Page conversion actions. Using this conversion action, you can specify the URL that should trigger a conversion.
However, there’s a catch: the conversion action doesn’t actually test “a visit to the external page”, but rather the fact that “the user click on a link that will take her to that external page.” As a result, this conversion action will only work if there’s a direct link from your WordPress site to the external page and might not be exactly measuring what you want (but it’s close enough).
Method 2. Redirecting your visitor back to WordPress
The easiest solution to overcome the fact that a user “left” your WordPress site and, therefore, you cannot track whether she fulfilled your conversion action or not is to redirect her back to WordPress once she’s converted. For instance, consider the following scenario:
- A visitor decides to buy a product or service you’re offering in your WordPress site.
- She then clicks on Buy and she goes to an external page called
http://external.com/checkout/
, where she’ll have to fill a form with some payment details. - Once she’s completed the form, she checks-out and the purchase is completed. The user is now in
http://external.com/purchase-completed/
.
In order to know that the purchase has been successful, we could add a redirection in http://external.com/purchase-completed/
page and send the user back to your WordPress site. You might be able to do this using the External website setup options or, if you have access to its source code, by adding a simple JavaScript such as:
<script type="text/javascript">
window.location = 'https://your-wordpress-site.com/thank-you/';
</script>
which redirects the user to a Thank You page in your WordPress site.
If you now use this Thank You page in your test (using a Page View conversion action), you’ll be able to track a conversion that occurred outside WordPress.
Please note this Thank You page can be an already existing page or a page you specifically created for tracking that conversion.
Please also note that the page should not be accessible from anywhere else, or you’d be counting conversions that could have never occurred.