Handlebars domain
Handlebars domain: returns everything behind the first @ of an email address, or null when the input has no @ or is not a string.
Next
Runtime verified
Test scripts included
Returns everything behind the first @ of an email address, or null when the input has no @ or is not a string.
Syntax
{{domain emailAddress}}
Returns string.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
emailAddress |
string | Yes | The email address to read the domain from. |
Example
Tested in a Marketing Cloud Next email on 2026-11-22:
{{domain "sales@force@example"}}rendersforce@example, as documented.{{domain "user@example.com"}}rendersexample.com, as documented.
Show Next test script
Marketing Cloud Next
Works as documented
Every tested call rendered the documented result. Tested 2026-11-22 by rendering in a Marketing Cloud Next email.
See also
- AMPscript
Domain— the AMPscript equivalent - Official reference