> ## Documentation Index
> Fetch the complete documentation index at: https://unify-19-preview.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Field mappings

> Choose how Salesforce fields sync.

export const CrmWriteBehaviors = () => <table>
    <thead>
      <tr>
        <th>Write behavior</th>
        <th>Effect</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><strong>Do nothing</strong></td>
        <td>Does not write the mapped Unify value to the CRM field.</td>
      </tr>
      <tr>
        <td><strong>Fill if empty</strong></td>
        <td>Writes the value when creating a record or when the existing CRM field is empty.</td>
      </tr>
      <tr>
        <td><strong>Overwrite on manual edit</strong></td>
        <td>Replaces the CRM value when that Unify field is manually edited, including when its value is cleared. Otherwise, fills the CRM field only when it is empty.</td>
      </tr>
      <tr>
        <td><strong>Overwrite always</strong></td>
        <td>Replaces the CRM value with the available Unify value. Empty Unify values do not clear the CRM field.</td>
      </tr>
    </tbody>
  </table>;

export const CrmReadBehaviors = () => <table>
    <thead>
      <tr><th>Behavior</th><th>Effect in Unify</th></tr>
    </thead>
    <tbody>
      <tr><td>Do nothing</td><td>Leave the Unify attribute unchanged.</td></tr>
      <tr><td>Fill if empty</td><td>Use the CRM value when the Unify attribute is empty.</td></tr>
      <tr><td>Overwrite</td><td>Replace the Unify value with the CRM value when it changes.</td></tr>
    </tbody>
  </table>;

export const ThemedImageFrame = ({lightSrc, darkSrc, alt, caption}) => <Frame caption={caption}>
    <img className="block w-full dark:hidden" src={lightSrc} alt={(alt ?? caption) ?? ""} />
    <img className="hidden w-full dark:block" src={darkSrc} alt={(alt ?? caption) ?? ""} />
  </Frame>;

## Overview

Field mappings pair Salesforce fields with Unify attributes and control how
values sync in each direction. For example, you can use Salesforce as the source
for company ownership while filling an empty phone number in Salesforce with a
value from Unify.

Mappings are shared by connections to the same Salesforce organization within your
Unify workspace. You need permission to manage the Salesforce integration to edit
them. [Sync rules](/reference/integrations/salesforce/bidirectional-syncs#sync-rules)
control when Unify writes records using these mappings.

## Configure field mappings

<Steps titleSize="h3">
  <Step title="Open an object mapping">
    Open [Settings → Salesforce](https://app.unifygtm.com/dashboard/settings/integrations/salesforce)
    and select the connection. Under **Field mappings**, click **Edit mapping**
    for the object you want to configure.

    Unify prepares mappings for standard fields when you connect. Review them
    before enabling bidirectional syncs, especially if your team uses custom
    fields in place of standard ones.
  </Step>

  <Step title="Choose the fields">
    Select the Unify attribute and corresponding Salesforce field in each row.
    Click **Add field** to add another pair.

    Choose compatible field types. The editor identifies required fields and
    limits the available choices for fields that cannot be read or written.
    Create a custom field in Salesforce before mapping to it.
  </Step>

  <Step title="Choose the sync behavior">
    Use **Sync to Unify** to choose the read behavior and **Sync to Salesforce**
    to choose the write behavior. These choices are independent: a field can be
    read into Unify while writes to Salesforce are disabled.

    <ThemedImageFrame lightSrc="/images/reference/integrations/salesforce/salesforce-field-write-behavior-light.png" darkSrc="/images/reference/integrations/salesforce/salesforce-field-write-behavior-dark.png" alt="Salesforce field mappings with the available write behaviors." />
  </Step>

  <Step title="Save the mapping">
    Resolve any required-field or compatibility warnings, then click **Save**.
    Changes to incoming mappings trigger background reprocessing of existing
    records for that object. Values update as that work progresses alongside
    regular syncs.

    Outgoing changes use the saved mapping on subsequent syncs. Review a write
    in **Sync log** to check the values sent to Salesforce.
  </Step>
</Steps>

## Read behavior

Read behavior controls how a Salesforce value updates its mapped Unify attribute:

<CrmReadBehaviors />

## Write behavior

Write behavior controls how a Unify value updates its mapped Salesforce field:

<CrmWriteBehaviors />

**Overwrite on manual edit** is available only for supported attributes.

Use [default values](/reference/integrations/salesforce/default-values) when a
field needs a fallback value during sync. Direct updates requested in chat
use the values supplied for that action.

## Ownership mappings

An engagement policy can depend on a company ownership mapping. Its ownership
attribute must read from the CRM with **Overwrite** and write with
**Overwrite on manual edit**. Changing or removing that mapping can disable
policy enforcement; the editor identifies affected policies before you save.

Coordinate ownership changes with the administrator responsible for your team's
engagement policies.

## Available fields

The editor lists the Unify attributes and Salesforce fields available for the
selected object. This includes supported custom attributes and fields.
Available choices depend on field type and the connected account's access.

Unify also provides activity and attribution values, such as the first or most
recent play and sequence associated with a person. To store one in a custom
Salesforce field, create a field with a compatible type and map the
corresponding Unify value.

## Troubleshooting

<AccordionGroup>
  <Accordion title="Why can't I save a mapping?">
    Review the warnings beside the affected fields. Required Unify attributes
    need a read mapping. Required Salesforce fields need a suitable write mapping
    or [default value](/reference/integrations/salesforce/default-values). Check
    that the selected field types are compatible.
  </Accordion>

  <Accordion title="Why is a field unavailable?">
    Confirm that the field exists on the selected Salesforce object and that the
    connected account can access it. Read-only fields cannot receive writes.
    Ask your Salesforce administrator to review the field's type and permissions
    if it remains unavailable.
  </Accordion>

  <Accordion title="Can I restore the standard mappings?">
    Open the object mapping and choose **Reset to default**. Review the
    confirmation before proceeding: the reset replaces your customized mapping
    and saves immediately. Check any ownership-policy warning before confirming.
  </Accordion>
</AccordionGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.