Freemarker allows you to personalize your emails to a great degree, from simply displaying the recipients’ names or personalizing subject lines, to using advanced if/then statements to show different content based on the recipients’ records, among other things.

But did you know that you can display the current date, time, or datetime in an email? Use Freemarker’s special variable, .now, along with date/datetime built-ins in order to return the current date and time. Here are some examples:

  • Date only, no time: ${.now?date}
  • Time of day only, no date: ${.now?time}
  • Date and Time: {.now?datetime}

You can use the “test” button to see your email and it will print out the correct values. You can also display a timestamp on the subject line.


Using the Test button

Blog 2

Test email in Outlook

Regarding any email template that has Freemarker, the best way to test is by sending it as an actual “email send”.

Blog 3

The same template, this time as an actual email send

For users that re-use the same template to send emails and want to display the date on the email itself (subject, preheader, or content), this could be a great tool to use so the date on the email does not have to be manually changed every time the email is sent. Other users that send internal emails may want to timestamp their emails for time-sensitive material.

Most ClickDimensions users likely won’t display the full datetime stamps in their emails, considering email clients also display the delivery date and time already—the redundancy of the date and time may be off-putting to some recipients. However, users that send transactional or compliance emails may find this useful when they need to display exact dates and times.

Happy Marketing!