Change Data Capture

Receive near-real-time changes of Salesforce records, and synchronize corresponding records in an external data store. Change Data Capture publishes change events, which represent changes to Salesforce records. Changes include creation of a new record, updates to an existing record, deletion of a record, and undeletion of a record.

Required Editions
Available in: both Salesforce Classic and Lightning Experience
Available in: Enterprise, Performance, Unlimited, and Developer editions
  • Keep Your External Data Current with Change Data Capture

    Use Change Data Capture to update data in an external system instead of doing periodic exports and imports of data or repeated API calls. Capturing changes with Change Data Capture event notifications ensures that your external data can be updated in real time and stays fresh.

  • Change Event Message Structure

    A change event message contains header fields and record fields.

  • Merged Change Events

    For efficiency, sometimes change events for one transaction are merged into one event if the same change occurred in multiple records of the same object type during one second.

  • Other Types of Change Events: Gap and Overflow Events

    Other types of change events are provided to handle special situations, such as capturing changes not caught in the Salesforce application servers, or handling high loads of changes.

  • Subscribe to Change Events

    Learn about subscribing to change events including subscription channels, subscription methods, and required permissions.

  • Monitor Change Event Publishing and Delivery Usage

    To get usage data for event publishing and delivery to CometD and Pub/Sub API clients, empApi Lightning components, and event relays, query the PlatformEventUsageMetric object. In API 58.0 and later, enable and use Enhanced Usage Metrics to get granular usage data for various time segments. If Enhanced Usage Metrics isn’t enabled, usage data is available for the last 24 hours, ending at the last hour, and for historical daily usage. PlatformEventUsageMetric is available in API version 50.0 and later.

  • Security Considerations

    Learn about the user permissions required for subscription, field-level security, and Shield Platform Encryption.

  • Change Event Considerations

    Keep in mind change event considerations and allocations when subscribing to change events.

  • Standard Object Notes

    Learn about the characteristics of change events for some standard objects and the fields included in the event messages.

  • Change Events for Fields

    Learn about the change event characteristics for fields.

See Also