Send Email as ADF

Auto-Lead Data Format or ADF is the automotive industry "standard" for sending emails to Customer Relationship Management (CRM) systems. By sending emails in this format CRM tools are able to parse email lead information into the corresponding fields for future use.


  • Gravity Forms
  • Basic CSS knowledge
  • Basic PHP knowledge (see NOTE 1)

Helpful links:

ADF/XML format guide:

XML checker:


GF by default sends out emails as 'Content-Type: text/HTML; ' Some CRMs can not handle the 'HTML' version of the lead. In order to change it to 'Content-Type: text/plain; ' you will need to add some PHP code to the functions.php file of your theme (DO NOT modify the actual functions.php file. If your theme contains a custom PHP section use that, or add a plugin, or similar)

Code is from: example 4

Add a notification 'Admin Notification - ADF' with the CRM email as the email address. The below code will allow only the ADF notice to be sent in ADF, otherwise, it will be HTML display.

//change GF notification from text-html to text-plain for a Specific Notification
add_filter( 'gform_notification', 'change_notification_format', 10, 3 );
function change_notification_format( $notification, $form, $entry ) {
 if ( $notification['name'] == 'Admin Notification - ADF' ) {

 // change notification format to text from the default html
 $notification['message_format'] = 'text';

 return $notification;
 } else {
 $notification['message_format'] = 'html';
 return $notification;

NOTE 2: Be cautious when using ADF/XML format, you must be in the 'text' tab of the notification. If you select the 'visual' tab the formatting will be ERASED!!! See 'adf-inventoryplead.txt' if you need to refresh it.

Create Form/Import Form

The GF attached can be used as a template if you want, it is set up in ADF format If you change anything with the form, be sure to change the GF ids in the notification area.

We have tied into the GF hooks by using the 'Parameter' fields under the 'Advanced' tabs. What this means is that when this form is on a VDP, it gets automatically populated with the value set up in the 'Parameter Name' field, in the examples below that would be the 'SaleClass' and the 'DealerId' (VMS id).

Config fields (single line text fields, or Hidden Fields: under Advanced class name, parameter name)

Setup Notification

Merge form content into ADF

From the ADF 1.0 PDF document, choose the field attributes that you would like to include. Add the ADF into the Text Editor near the bottom of the Notification section. Make sure not to use the Visual Mode when working with ADF as it will get removed when you save the page. Make sure that all the elements of your ADF are opened and closed.

Once your ADF is in place use the merge function (dropdown arrow on right) to insert the corresponding attributes.