Create an XDM schema for web data

We expect to publish major changes to this tutorial on Tuesday April 23, 2024. After that point many exercises will change and you may need to restart the tutorial from the beginning in order to complete all of the lessons.

Learn how to create an XDM schema for web data in the Data Collection interface.

Experience Data Model (XDM) schemas are the building blocks, principles, and best practices for composing schemas in Adobe Experience Platform.

Platform Web SDK uses your schema to standardize your web event data, send it to the Platform Edge Network, and ultimately forward the data to any Experience Cloud applications configured in the datastream. This step is critical as it defines a standard data model required for ingesting customer experience data into Experience Platform and enables downstream services and applications built on these standards.

For demonstration purposes, the exercises in this lesson build an example schema to capture content viewed and products purchased by customers in the Luma Demo Site. While you can use these steps to create a different schema for your own purposes, it is recommended that you first follow along with creating the example schema to learn the capabilities of the schema editor.

To learn more about XDM schemas, take the course “Model Your Customer Experience Data with XDM” or see the XDM System overview.

Learning objectives

At the end of this lesson, you will be able to:

  • Create an XDM schema from within the Data Collection interface
  • Add field groups to your XDM schema
  • Create XDM schemas for web event data using best practices


All necessary provisioning and user permissions for Data Collection and Adobe Experience Platform described in the Configure Permissions lesson.

Create an XDM schema

XDM schemas are the standard way to describe data in Experience Platform, allowing all data that conforms to the schemas to be reused across an organization without conflicts, or even shared between multiple organizations. To learn more, see the basics of Schema composition.

In this exercise, you will create an XDM schema using the recommended baseline field groups for capturing web event data on the Luma Demo Site:

  1. Open the Data Collection interface

  2. Make sure the you are in the correct sandbox

    note note
    If you are the customer of a Platform-based application like Real-Time CDP, we recommend using a development sandbox for this tutorial. If you are not, use the Prod sandbox.
  3. Go to Schemas in the left navigation

  4. Select the Create Schema button on the top right

  5. From the dropdown menu, select XDM ExperienceEvent

Schema Experience Event

Add field groups

As noted earlier, XDM is the core framework that standardizes customer experience data by providing common structures and definitions for use in downstream Adobe Experience Platform services. By adhering to XDM standards, all customer experience data can be incorporated into a common representation. This approach allows you to gain valuable insights from customer actions, define customer audiences through segments, and express customer attributes for personalization purposes using data from multiple sources. See Best practices for data modeling for more information.

When possible, it is recommended to use existing field groups and adhere to a product-agnostic model and naming conventions. For any data specific to your organization that does not fit into the pre-defined field groups above, you can create a custom field group. See Creating a schema using the Schema Editor for more detailed steps on custom schemas.

In this exercise, you add the recommended pre-defined field groups for web data collection: AEP Web SDK ExperienceEvent, and Consumer Experience Event.
  1. In the Field groups section, select Add

  2. Search for AEP Web SDK ExperienceEvent

  3. Check the box

  4. Search for Consumer Experience Event

  5. Check the box

  6. Select Add field groups

    Add Field Group

With the field groups selected, you are ready to name your schema. A common naming convention for XDM schemas is to name the schema after the source of the data:

  1. In the Composition panel, select the Untitled schema name
  2. In the Schema properties panel, enter the Display Name Luma Web Event Data
  3. Select anything outside of the Display Name field to activate the Save option
  4. Select Save

Luma Web Event Data

With both field groups, notice that you have access to the most commonly used key-value pairs required for data collection on the web. The display name of each field appears to marketers in the segment builder interface of Platform-based applications and you can change the display name of standard fields to suit your needs. You can also remove fields you don’t want. When you click on either field group name, the interface highlights what key-value pair groupings belong to it. In below example, you see what groups belong to Consumer Experience Event.

Schema Field Groups

This lesson is just a starting point. When building your own web events schema, you must explore and document your business requirements. This process is similar to creating a Business Requirements Document and Solution Design Reference for an Adobe Analytics implementation, but should include requirements for all downstream data recipients such as Platform, Target, and event forwarding destinations.

The identityMap object

There is a special set of data required to identify web users called identityMap.

Luma Web Event Data

It is a must-have object for any web-related data collection, as it houses the Experience Cloud ID required for identifying users on the web. It is also the key to setting internal customer IDs for authenticated users. identityMap is discussed more in the Configure Identities lesson. It is automatically included in all schemas using the XDM ExperienceEvent class.

It is possible to enable Profile for a schema before saving your schema. Do not enable it at this point. Once a schema is enabled for Profile, it cannot be disabled or deleted. Also, fields cannot be removed from the schema after this point. These implications are important to keep in mind later on when you are working with your own data in your Production environment.
This setting is discussed more during the Setup Experience Platform lesson.
Profile Schema

Now you are able to reference this schema when you add the Web SDK extension to your tag property.

Next: Configure an identity namespace

Thank you for investing your time in learning about Adobe Experience Platform Web SDK. If you have questions, want to share general feedback, or have suggestions on future content, share them on this Experience League Community discussion post