---
schema_version: "1"
id: 2a63b68d1cd065a449761d30c0734a8cf4531bec310f1e29400e4ea63c04bc5d
title: Merge Fields for Custom Buttons and Links
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/platform/264-0-0/links_merge_fields.md
canonical_url: https://help.salesforce.com/s/articleView?id=platform.links_merge_fields.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 4d5eca17cd714ad4d48a1692c7de4085cc3ede81387796266c479e55eab8bec1
description: A merge field is a field that incorporates values from an object record. You can put merge fields in an email template, mail merge template, custom link, or formula.
products:
  - Salesforce Platform
  - Security
release: "264"
---
# Merge Fields for Custom Buttons and Links

A merge field is a field that incorporates values from an object record. You can put merge fields in an email template, mail merge template, custom link, or formula.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition">
      <colgroup>
        <col>
      </colgroup>
      <tbody>
        <tr class="">
          <td class="slds-cell-wrap" style="vertical-align:top;">Available in: Salesforce Classic</td>

        </tr>
        <tr class="">
          <td class="slds-cell-wrap" style="vertical-align:top;">
            <p>Custom buttons and links are available in: <strong>All</strong> Editions</p>
            <p style="margin-bottom:0;">Visualforce
              pages and s-controls are available in: <strong>Contact Manager</strong>, <strong>Group</strong>,
              <strong>Professional</strong>, <strong>Enterprise</strong>, <strong>Performance</strong>, <strong>Unlimited</strong>,
              and <strong>Developer</strong> Editions
            </p>
          </td>

        </tr>
      </tbody>
    </table>

## Syntax and Formatting

When you insert a merge field in a custom button or link, the syntax consists of an open curly brace and exclamation point, followed by the object name, a period, the field name, and a closing curly brace.

```
{!Object_Name.Field_Name}
```

To ensure that you’re using the correct syntax, select merge fields from the dropdown list in the editor for custom buttons and links.

![Note](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-platform-extend_click-264-0-0-production-enus/5f7d9219-b7b1-4552-8891-f1aba9b289fc/images/icon_note.png)

Note Custom objects named Org can’t be used in a merge field. Objects named org are explicitly filtered from the Select Field Type list for a custom button.

## Tips

- To insert activity merge fields, select **Event** or **Task** from the Select Field Type dropdown list.
- You can add links quickly to the sidebar by using the standard home page’s Custom Links component.
    
    ![Warning](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-platform-extend_click-264-0-0-production-enus/5f7d9219-b7b1-4552-8891-f1aba9b289fc/images/icon_warning.png)
    
    Warning The standard home page’s Custom Links component doesn’t support
    
    - Merge fields
    - Functions, such as `URLFOR`
    - JavaScript execution
    - Customizable window opening properties

#### See Also

- [Generate Emails From Records](https://help.salesforce.com/s/articleView?id=valid_merge_fields.htm&language=en_US)
- [Custom Button and Link Considerations](https://help.salesforce.com/s/articleView?id=platform.links_considerations.htm&release=264.0.0&type=5 "Keep these considerations in mind when working with custom buttons and links.")