🎉 Celebrate with 10% OFF on All Products! Use Code: GFEX10 Or Buy Any 2+ Items for 30% OFF with Code: GFEX30!

Gravity Forms Advanced Merge Tags Premium Add-on Setup Guide

Updated 6 min read Gravity Forms Fields & Inputs
On this page
  1. Video walkthrough
  2. Step 1: Install and Activate Your License
  3. Step 2: Try Tags on the Preview Page
  4. Field Modifiers
  5. Text
  6. Dates
  7. Numbers
  8. Encoding and tokens
  9. Standalone Tags
  10. Entry Lookups
  11. Escaping and Security
  12. Limits and What Is Not Included in v1.0
  13. Troubleshooting & FAQ
  14. My tag is shown as typed.
  15. A lookup returns nothing.
  16. My date format has a comma.
  17. Can I use the tags in feeds and PDFs?
  18. What happens when I uninstall the add-on?

Video walkthrough

Gravity Forms Merge Tag Modifiers: Format Dates, Do Maths & More
Watch: format dates, do maths and personalise Gravity Forms merge tags Watch on YouTube

The Gravity Forms Advanced Merge Tags Premium Add-on lets you transform any merge tag where it is used: change the case of a name, format or shift a date, do maths, mask a phone number, encode a value for a link, or look up earlier entries. It works in notifications, confirmations, feeds and every other place where Gravity Forms replaces merge tags.

This guide covers installation, the preview page, field modifiers, standalone tags, entry lookups and their access settings, escaping and security, the limits of version 1.0 and troubleshooting.

System Requirements & Prerequisites

  • WordPress: Version 6.5 or higher
  • PHP: Version 7.4 or higher
  • Gravity Forms: Version 2.9 or higher, any licence
  • GravityExtra license: The add-on installed, activated and licensed with an active GravityExtra license key

Step 1: Install and Activate Your License

  1. In WordPress go to Plugins → Add New → Upload Plugin, upload the add-on ZIP file and click Activate.
  2. Go to Forms → Settings → Merge Tags, enter your key in the Gravity Extra License section and click Activate License.
  3. Existing merge tags keep working exactly as before. The new modifiers only apply where you add them.

Step 2: Try Tags on the Preview Page

Open Forms → Merge Tags. Choose a form and one of its entries, type text with merge tags and click Preview. The result is shown as it would appear in a plain-text email. Below the preview you find the full reference of modifiers and standalone tags.

Merge Tags preview page: a form and entry are selected, the text box holds tags with modifiers such as trim, title, a signed token and today plus 2 working days, and the result below reads Hi Ada, a reference code and a weekday date
The preview page shows the result for a real entry.

Field Modifiers

Add modifiers after the field ID of any field merge tag, separated by a vertical bar |. They run from left to right. Arguments go in brackets and are separated by commas; put an argument in double quotes when it contains a comma, a bracket or a vertical bar.

  • {Name:1.3:trim|title} → Ada from “ aDA ”.
  • {Email:2:split(@,2)|upper} → the email domain in capitals.
  • {Message:4:truncate(80)} → the first 80 characters, ending with ….
  • {Phone:6:mask(4)} → all but the last four digits replaced by *.
  • {Start date:3:dateadd(2 workdays)|dateformat(l, F j, Y)} → Tuesday, October 20, 2026.
  • {Hours:5:mul(15)|money} → the hours times 15, formatted in the form currency.

Gravity Forms’ own modifiers still work, and can come first: {Shift:7:value|upper} takes the choice value, {Shift:7:upper} the choice label. A modifier the add-on does not know is left to Gravity Forms.

Reference of field modifiers grouped into Text, Dates, Numbers and Encode and tokens, each with its arguments and a short description
The built-in reference on the preview page.

Text

upper, lower, title, sentence, trim, striptags, truncate(length, ending), substr(start, length), replace(find, replace), split(separator, part), length, wordcount, censor(word, word), mask(visible), initials, slug, default(text) and wrap(before, after).

Dates

dateformat(format) uses PHP date letters, for example F j, Y or d/m/Y, and the site language for month and day names. dateadd(7 days) and datesub(1 month) accept days, weeks, months, years, hours, minutes and workdays; working days skip Saturdays and Sundays. Adding a month to January 31 gives the last day of February. timezone(Europe/London) converts a date and time, and age, daysuntil and dayssince count whole years or days. Date fields are read in their stored format, so the result does not depend on the date format shown in the form.

Numbers

add(n), sub(n), mul(n), div(n), round(decimals), ceil, floor, abs, number(decimals) (thousands separators, optional custom separators) and money (the form currency). Values like “$1,250.00” are read as numbers. A division by zero or a value that is not a number gives an empty result.

Encoding and tokens

urlenc, base64, md5, sha256, json and hmac(length), a signed code made from the value and a secret of your site, useful for links that should not be guessed.

Standalone Tags

  • {gx:today} and {gx:now}: the date (and time) in the site time zone. They also work in field default values, for example {gx:today|dateadd(7 days)|dateformat(m/d/Y)}.
  • {gx:calc:{Qty:3} * {Price:4} * 1.2|round(2)}: arithmetic with + − × ÷ %, powers, brackets and round, floor, ceil, abs, min, max and sqrt. Each merge tag inside is read as a number; empty or text counts as 0. No code is ever run.
  • {gx:value:{Name:1.3} {Name:1.6}|initials}: combine merge tags and text, then apply modifiers.
  • {gx:entry prop="date_created"}: entry data — id, date_created, date_updated, source_url, payment_status, payment_amount, transaction_id, currency. Dates are in the site time zone.
  • {gx:user prop="first_name"}: the user who submitted the entry — id, login, email, display_name, first_name, last_name, role or meta:key.
  • {gx:post prop="title"}: the page the form was submitted on — id, title, url, type, author or meta:key.
  • {gx:url param="utm_campaign"}: a parameter of the page address, or part="host", "path" or "query".
  • {gx:token}: a signed code for the entry, 32 characters by default (length="12" for shorter).

Entry Lookups

Lookups read other entries: {gx:count match="2" value="{Email:2}"} counts entries with the same email, {gx:sum form="5" field="3" match="2" value="{Email:2}"} adds up a field of matching entries in form 5 (up to 5,000 entries), and {gx:get form="5" field="4" match="2" value="{Email:2}"} returns a field of the newest matching entry. Add days="30" to read only recent entries and exclude="current" to leave out the entry being processed.

Lookups are switched off until you allow them. Open the form whose entries will be read, go to Form Settings → Merge Tags, switch on Allow lookup merge tags to read entries of this form and tick the forms that may read it — also the form itself for same-form lookups.

Form Settings Merge Tags tab with Lookup access switched on and a list of forms that may read the entries, with Volunteer sign-up ticked
Lookup access is set on the form being read.

Escaping and Security

  • Every result is escaped for its location: HTML-escaped in HTML emails and confirmations, URL-encoded in redirect URLs and plain in text emails.
  • Merge tags typed by a visitor into a field are never run, even after a modifier such as upper.
  • User and post meta keys that look private (passwords, tokens, sessions, keys, capabilities or keys starting with an underscore) always return nothing.
  • A lookup can show data from other entries wherever you use it, including confirmations that visitors see. Allow only the forms and fields those visitors may see.

Limits and What Is Not Included in v1.0

  • Working days skip weekends only; public holidays are not taken into account.
  • Modifiers apply where Gravity Forms replaces merge tags on the server. Live in-form calculations and the browser-side preview of Gravity Forms do not run them.
  • A sum reads at most 5,000 entries.
  • Without an active license the tags are left as typed and Gravity Forms’ own merge tags work as usual.

Troubleshooting & FAQ

My tag is shown as typed.

Check the spelling of the modifier and the brackets on the preview page. An unknown modifier anywhere in a chain leaves the whole tag to Gravity Forms.

A lookup returns nothing.

Open Form Settings → Merge Tags on the form being read and allow the form that runs the lookup. Check that match and field are field IDs of that form.

My date format has a comma.

That is fine: dateformat(F j, Y) takes everything inside the brackets as the format.

Can I use the tags in feeds and PDFs?

Yes, wherever the add-on that sends the feed or builds the document uses the standard Gravity Forms merge tag replacement.

What happens when I uninstall the add-on?

Forms → Settings → Uninstall removes the add-on settings. Tags in your notifications stay as typed.

Still need help?

Our support team answers tickets every day, usually within a few hours.

0
0
Your Cart
Your cart is emptyReturn to Shop
🔥 FREQUENTLY BOUGHT TOGETHER
Complete Combo & Save 40%!
ITEM IN YOUR CART
Gravity Forms Klaviyo Add-on
$39.00/yr
+
🎁 RECOMMENDED ADD-ON SAVE 40% OFF
Original Price: $39.00/yr
Bundle Special Price: $23.40/yr