---
title: "Map data from an XM data source to a component"
slug: "map-data-from-an-xm-data-source-to-a-component"
abstract: "Map the attributes of an element with the templates of an XM data source."
---
# Map data from an XM data source to a component

To map data from an XM data source to a component:

1. Add an element to the component, or click an existing element.
2. In the right-hand pane, in the **Content** section, click the attribute you want to configure for the selected element. For example, for an *Image* element, the attributes that can be configured with mapped data are *Image source*, *Caption*, *Image alternative text*, or *Link*.
3. Click **Mapped** to open the **Data collection** dialog.
4. In the **Data collection** dialog, in the **Source** step, select the relevant XM data source from the drop-down list.

    > [!note]
    > If you've previously selected a data source for this component, it is automatically selected when the dialog appears. Click the Source icon or the Back button at the bottom of the right -hand pane if you need to select a different one.

5. In the **Data collection** dialog box, in the **Path** step, the data tree displays applicable properties that can be used as value for the attribute. Click the appropriate property for the attribute.
6. Click **Complete**.