You are here:
Add Images to Email Templates in Salesforce Classic
You can include images, such as logos, in your custom HTML and Visualforce email templates. Salesforce allows you to use style tags to add external or internal images to an email.
Required Editions
| Available in: Salesforce Classic |
| Available in: All Editions, except Personal |
HTML and Visualforce email templates not available in: Personal Edition |
| Visualforce Classic email templates can’t be used in Lightning Experience |
| User Permissions Needed | |
|---|---|
| To create or change HTML email templates: | Edit HTML Templates |
| To create or change Visualforce email templates: | Customize Application |
| To create or change public email template folders: | Manage Public Classic Email Templates |
When creating custom HTML or Visualforce templates, use an <img> tag to reference the image. We recommend
uploading the images to the Documents tab and referencing the copy of the image on
the Salesforce server.
- Add an image to the Documents tab.
- On the Documents home page, open the image by clicking its name.
- Right-click the image and get its reusable URL address. When you use the URL, you reference the copy of the image on the Salesforce server.
- Open your custom HTML or Visualforce template.
-
Place the HTML tag
<img>, using the image’s URL address, where you want to insert the image in the email template.
<img
src="http://www.401khelpcenter.com/syndicate/img/AF-Logo_Brown_Small.gif"
alt="Logo"/>. However, if an image is stored in your org, you have more
control over it.Use the style
attribute in HTML to add internal and external images to email templates whose HTML
elements can be edited.
Custom (without using Classic Letterhead)
<img src="https://yourInstance.salesforce.com/servlet/servlet.ImageServer?
id=015D0000000Dpwc&oid=00DD0000000FHaG&lastMod=1270576568000"/>
<apex:image id="Logo" value="https://yourInstance.salesforce.com/servlet/servlet.ImageServer?
id=015D0000000Dpwc&oid=00DD0000000FHaG&lastMod=127057656800" />
This example adds an image as the background on an HTML element.
<td style="height:33; background-image:url('https://yourInstance.salesforce.com/
/servlet/servlet.ImageServer?id=015D0000000Dpwc&oid=00DD0000000FHaG&lastMod=1270576568000">

