Home

THE
AMPSCRIPT GUIDE

Master AMPscript with the definitive scripting manual for Salesforce Marketing Cloud

About The AMPscript Guide

AMPscript is a scripting language for Salesforce Marketing Cloud. You can use it to create highly sophisticated, personalized content through an extensive set of functions.

The language follows a simple syntax and semantics. With an understanding of the fundamentals, you can quickly gain proficiency in AMPscript — no prior experience in scripting languages is needed.

This book extends the existing Salesforce documentation to provide an authoritative reference manual on AMPscript. Whether you are inexperienced in writing scripts or are already highly proficient in AMPscript, this book will enable you to enjoy rapid development through clear explanations and extensive documentation on all AMPscript functions, including real-world supporting code samples for you to reuse.


What people are saying

Gaurav Kheterpal @gauravkheterpal

This is an essential resource that fills the gap between official documentation and real world scenarios — highly recommended!

Patricio Sapir @patosapir

This is the ultimate guide for anyone either getting started with AMPscript or advanced developers who need solid reference material.

Calvin Smith @CloudMech

This book will save you a lot of time searching for answers to questions you’re likely have. I highly recommended it!

Andrew Corr @andrew_c_au

Packed with examples and clear definitions, this is the ultimate handbook for anyone who wants to understand AMPscript.


The AMPscript Guide Understand how to use AMPscript to your advantage today

Meet the Authors

Eliot Harper Salesforce MVP

Eliot is a Marketing Cloud Consultant at AttributeValue based in Melbourne, Australia. Eliot provides AMPscript training and consulting to companies around the world and has written several books on Marketing Cloud. Eliot is a regular speaker at international and community events.

Adam Spriggs Salesforce MVP

Adam is the Marketing Cloud Engineering Team Lead at DEG in Kansas City. Working with a wide variety of global clients has afforded Adam a depth of experience in Marketing Cloud, specifically AMPscript. Adam is an active contributor on Salesforce StackExchange.


Chapters

This book is a comprehensive reference manual for AMPscript. It explains how to quickly get started with the language and provides carefully categorised and documented functions, with supporting code samples for real-world scenarios.

i.Foreword
ii.Introduction
1.Language
2.Personalization Strings
3.Marketing Cloud API Functions
4.Contact Model Functions
5.Content Functions
6.Data Extension Functions
7.Date & Time Functions

8.Einstein Email Functions
9.Encryption & Encoding Functions
10.HTTP Functions
11.Math Functions
12.Microsoft Dynamics CRM Functions
13.MobileConnect Functions
14.Sales & Service Cloud Functions
15.Site-Based Functions
16.Social Functions

17.String Functions
18.Utility Functions
19.Exclusion Scripts
20.AMPscript & Guide Template Language
21.AMPscript & Server-Side JavaScript
22.Content Syndication
23.Best Practices