Integrating with Adobe Test&Target

You are reading the AEM 5.6.1 version of Integrating with Adobe Test&Target.
This version has reached End of core support. For further details see our technical support periods.
This documentation is also available for the following versions:  AEM 6.2  AEM 6.1  AEM 6.0  AEM 5.6 

As part of the Adobe Marketing Cloud, Adobe Target (formerly Adobe Test&Target) lets you increase content relevance through targeting and measuring across all channels.

Adobe Test&Target is used by marketers to design and execute online tests, create on-the-fly audience segments (based on behavior) and automate the targeting of content and online experiences.

Adobe Test&Target puts control directly in the hands of marketers to quickly and continually execute multiple A/B testing and multivariate (MVT) testing, measure effectiveness and relevance of content across any online channel and increase content relevance through segmentation, targeting and automated personalization.

With AEM your site can be seamlessly integrated with Adobe Target, allowing you to do the following:

  • Create campaign offers with AEM and manage them with Adobe Target.
  • Submit Client Context data to Adobe Target when visitors interact with your pages.
  • Implement landing page campaigns.
  • Perform A/B testing.
  • Track conversion rates.

A typical integration with Test&Target involves the following steps:

  1. Register with Adobe Target to create an account.
  2. Create a Test&Target configuration in AEM. (On this page.)
  3. Associate the Test&Target configuration with your AEM Campaign. (On this page.)
  4. Associate the Test&Target configuration with your AEM website. (On this page.)
  5. Create a Test&Target framework that identifies the visitor data that you want to track. (On this page.)
  6. Associate the framework with your web pages. (On this page.)
  7. Add code to your web pages so that it can access the Adobe Target infrastructure.  (See Developing for Targeted Content.)
  8. Add Target components to your web pages to create offers. (See Content Targeting.)
  9. Managing the generated data in Adobe Target.

If required, you can customize the default behavior of the integration with Adobe Target. (See Developing for Targeted Content.)


If a custom mbox is defined in a Target configuration, everyone must have read access to/etc/cloudservices on publish servers. Without this access, loading mbox.js files on publish website results in a 404 error. 

In addition, the ACLSetupService component also requires the folowing change as it sets a deny ACE on /etc/cloudservices everytime the security bundle is restarted or refreshed:

/libs/cq/security/config.publish/ should have entry 15 removed.

When to use T&T integration instead of just AEM

With Test&Target you can create campaign for A/B testing, multivariate testing and you can run complex reports, while in AEM you can create complex segments but the out-of-the-box strategies to run campaigns are limited to first, random and clickstream score. AEM can only report on clicks, there is no conversion optimization.

You can use AEM by itself to create segments and serve randomly with limited reporting. If you would like to optimize your content, do complex multivariate testing or implementing complex rules to run a campaign you should use Test&Target.

Background Information Sources

Integrating AEM with Adobe Target requires knowlege of Adobe Target and AEM campaign management. You should be familiar with the following information:

Setting Up your Site with Test&Target

Use the following procedures to integrate your AEM website with Adobe Target.

Registering with Test&Target

To integrate AEM with Adobe Target, you must have a valid Adobe Target account. This account must have editor level permissions at a minimum. When you register with Adobe Target, you receive a client code. You need the client code and your Adobe Target login name and password to connecting AEM to Adobe Target.

The Client Code identifies the Adobe Target customer account and is used as a sub-domain in the URL when calling the Adobe Target server. 

Before proceeding, ensure your credentials allow you to login here:

Creating a Test&Target Configuration in AEM

To enable AEM to interact with Adobe Target, create a Test&Target cloud configuration in AEM. To create the configuration, you provide the Adobe Target client code and user credentials.

You create the Test&Target cloud configuration only once because you can associate the configuration with multiple AEM campaigns. If you have several Adobe Target client codes, create one configuration for each client code.

Use the following procedure to create a Test&Target cloud configuration in AEM:

  1. Go to the Tools page and select Cloud Services. (http://localhost:4502/libs/cq/core/content/tools/cloudservices.html)

    The Adobe Marketing Cloud overview page opens.

  2. In the Adobe Test&Target section, click Configure Now.

  3. In the Create Configuration dialog:

    1. Give the configuration a Title.
    2. Select the Adobe Test&Target Configuration template.
    3. Click Create.

    The edit dialog opens for the new configuration page.

  4. In the dialog, provide values for the properties:

    1. Client Code: the Test&Target account Client Code
    2. E-Mail: the Test&Target account email.
    3. Password: the Test&Target account password.
    4. Custom mbox.js: Leave blank to use the default mbox.js. Otherwise upload your custom mbox.js.
  5. Click Connect to Test&Target to initialize the connection with Test&Target. If the connection is successful, the message Connection successful is displayed. Click OK on the message and then OK on the dialog. The configuration page will now look like this:


Associating Your Website With the Test&Target Configuration

Configure your AEM website to use the Test&Target configuration so that target-related scripts on your pages can access the configuration properties when required.

When you associate a web page with the Test&Target configuration, the child pages inherit the association. 

  1. In the Websites console, in the websites tree, select the folder or parent page of the site that you wish to configure.

  2. In the list of pages, right-click the page and click Properties.

  3. Select the Cloud Services tab.

  4. Click Add Service, select Adobe Test&Target and click OK.

  5. Use the Adobe Test&Target drop-down menu to select your T&T configuration.


    Make sure that you select the specific configuration that you created and not a T&T framework.

  6. Click OK to save the changes.

  7. Activate the root page of the website to replicate it to the publish server. (See How To Publish Pages.)

Creating a Test&Target Campaign in AEM

Associate your AEM campaigns with your Test&Target configuration so that you can mirror the campaign in Adobe Target.

When you associate the AEM campaign with your Test&Target configuration, a corresponding campaign is automatically created in Adobe Target (there may be a delay before this occurs). As you modify the campaign the changes are automatically reflected in Adobe Target. Note that the campaign is updated in Adobe Target only when at east one offer exists for the campaign in your web pages. (See Content Targeting.)

The name of the AEM campaign is the name used in Adobe Target. Make sure that the name is distinguishable and recognizable among other campaigns managed in Adobe Target.

Before you perform the following procedure, you must have aleady created your AEM campaign. (See Campaign Management.)  

  1. In the Website console, select your brand below /Websites/Campaigns. (http://localhost:4502/siteadmin#/content/campaigns)

  2. In the list of campaigns, right-click the campaign and click Properties.

  3. On the Cloud Services tab, click Add Service, select Adobe Test&Target, and then click OK. 

  4. Use the Adobe Test&Target drop-down menu to select your Test&Target configuration, and then click OK.


    Make sure you select the configuration and not a Framework that you created within it.

  5. To replicate your changes to the publish instance, select the campaign and click Activate.

You have now created a new Campaign and connected it to your Adobe Target account.

Campaigns on Author and Publish Instances

When a T&T-enabled campaign is activated, a second T&T campaign is created on the publish instance:

  • The T&T campaign on the author instance tracks activity on the author instance and is useful for simulating the visitor experience. The analytics recorded for this campaign only reflect the activity occurring on the author instance.
  • The T&T campaign on the publish instance reflects and responds to the activity on the publish server. This is the campaign that runs the public website. Only the publish campaign is relevant to tracking and analyzing the usage of the actual public site.

In Adobe Target, the name of the campaign on the author instance has the _author suffix.


Add a Framework

After you configure the T&T connection, add an analytics framework. The framework identifies the default parameters that are sent to Adobe Target from the targeted components (mboxes) on your AEM pages:

You can create multiple frameworks for a single Test&Target configuration. However, a web page can use only one framework at a time.

  1. On your T&T configuration page, click the + (plus sign) next to Available Frameworks.

  2. In the Create Framework dialog, specify a Title, select the Adobe Test&Target Framework, and click Create.


    The framework page opens. Sidekick provides components that represent information from the Client Context that you can map.

  3. Drag the component that represents the data that you want to use for mapping to the drop target.

    For example, to use Profile Data about your site vistors to control your T&T campaign, drag the Profile Data component to the page. The profile data variables that are available for mapping to T&T parameters appear. 

  4. Select the variables that you wish to make visible to the T&T system.



    Synchronizing the campaign parameters is one way only - from AEM to Test&Target.

Your framework is created. Perform the following procedure to replicate the framework to the publish instance:

  1. Open the Tools console (