You're viewing help content for version:

Target in AEM Forms

Adobe Target integrated with AEM lets you create experiences customized for a target audience. With Adobe Target, you can create A/B tests, measure user response, and generate customized web content for targeted users.

Adobe Target for AEM Forms lets you create activities that enable image content for a target audience, and measure user response.  

To use Target, configure it in AEM. To configure Target in AEM, see Creating a Target Configuration in AEM and Add a Framework.


Targeting works when your adaptive form is rendered using a host name or IP address. It fails when your adaptive form is rendered using localhost. 

Creating a Target Activity

  1. Tap Adobe Experience Manager > Personalization > Activities


  2. In the Activities page, tap Create > Create Brand.

  3. You are asked to choose a template and enter properties.
    Select a template, tap Next. Enter the title of your brand in the Properties section, and tap Create.
    Your brand is now listed in the Activities page. 

  4. Tap your brand in the Activities page. 

  5. In Master Area of your brand, tap Create > Create Activity.
    When you create an activity, you specify its details, target, and settings.

    The Details section includes name, targeting engine, and objective. When you select Adobe Target as the targeting engine, you get Target cloud configuration option enabled. Choose your Target cloud configuration, provide the objective of the activity, and tap Next

    The Target section lets you add audience experience and name it. Click Add Experience to enable the Select Audience and Name Experience options. Tap Select Audience to see a list of audiences and their source. Select an audience from the Audience Name list. Tap Add Experience to name the experience, and tap Next.

    The Goals & Settings section lets you schedule and prioritize your activity. Set the start date, end date, and priority of the activity, and tap Save.

    The activity is now listed in your brand page. 

  6. To enable target, edit the .jsp file to include client libraries that your adaptive forms template uses.

    For example, in the out-of-the-box implemenation, click Tools > CRXDE Lite.

    In the CRXDE Lite address bar, type /libs/fd/af/components/page/base/head.jsp to edit the head.jsp file.

    This implementaion uses simpleEnrollment template. In this implementation, modify the head.jsp file to include the following client libraries: 

    <cq:include script="/libs/cq/cloudserviceconfigs/components/servicelibs/servicelibs.jsp"/>

    <cq:include path="clientcontext_optimized" resourceType="/libs/cq/personalization/components/clientcontext_optimized"/>

    <cq:include path="config" resourceType="cq/personalization/components/clientcontext_optimized/config"/>

  7. To enable target framework for adaptive forms, navigate to your form, and open it in edit mode.

    To open a form in edit mode, tap Select, and then tap Open.

    Alternatively, four buttons appear when you move your pointer over the form icon without selecting it. You can tap the Open button that appears, to open the form in edit mode. 

  8. In the page toolbar, tap  Page Information > Open Page Properties

  9. In the Page dialog that appears, tap CLOUD SERVICES.

  10. In the Cloud Services tab, under Cloud Service Configurations, tap Add Configuration > Adobe Target.  

  11. Adobe Target is enabled under Cloud Service Configurations. Select your configuration from the drop-down list, and tap Done .

Applying created activity to an adaptive form image

  1. Open the form in Classic UI.
    To open the form in classic UI, tap > Open in Classic UI in the page toolbar.

  2. In the authoring mode, add an image to your adaptive form. 

  3. Select the image component, right-click on it, and click Target in the menu.

    The Target menu appears on top of the image component. 

  4. In the Target menu, select the activity that you created from the drop-down list. 

    When you select your activity, the experiences you defined are visible under it. 

  5. In the Target menu, click the settings icon.

    In the settings dialog box that appears, select Adobe Target as the Engine and click OK.

    Flowchart of the steps above
    Click to view the full-size image

  6. To edit the image for an experience, select the experience, right-click on it, and click Edit in the menu.

    To include an experience in the Target activity, click the + button that appears when you move your pointer over the experience that you defined.

    If you include an experience in the target activity, ensure that you edit its image.


    Visibility expression fails with Target.

    Flowchart of the step above

Check if the created activity syncs with the Target server

An activity used for targeting syncs with the Target server. To check if your activity is in sync with the target server, check the status of your activity in your brand page.

Ensure that the status of the activity is Synced. 

Validate Target behavior

To validate Target behavior:

  • Use targeting with wcmmode preview in the author mode
  • Use targeting with wcmmode preview and wcmmode disabled in the publish mode

Monitor targeting for the image component

To monitor targeting for image components on your form, publish your images, activities, and adaptive form.  

Target Reports in AEM

To see Target reports, on publish instance type: http://<hostname>:<port>/libs/cq/contentinsight/content/insight.html/content/forms/af/myAF

This implementation is not showing complete reports. 

Workaround: Configure analytics server and add its configuration in AEM sidekick > Page > Page Properties > Cloud Services dialog. It lets you see a report similar to the one below:


Target server lets you see detailed reports. 

Open Issues

Visibility expression, set focus fail for targeted images on adaptive forms.