How can I use tokens in Mass Mail attachements? For example, I would like to add .docx or .pdf as attachement that already contains tokens in text and then let CiviCRM replace them for each contact while sending it?

I know this functionality is implemented in Print/Mail merge, but I don't know if I do it that way, how can I send them via email that created document instead of downloading it to my computer...

Thank you in advance, Aleksandar

2 Answers 2


I don't know of a way to do this. When I had a similar need I mail-merged in Word, then generated PDFs with the relevant Contact ID in the filename. I then uploaded all these and used a token to link to the relevant PDF for each contact.

Not super elegant, but worked. Admittedly I was in a hurry and didn't research fully. Hopefully others may know of something better.

I think I had to use the Merge Tools extension to generate the PDFs with merge-fields in the filename.


I cannot think of a way CiviCRM can do this, basically you are asking the mailing software to open a Word Doc template, insert tokens, save it and then send it onwards. Also your bandwidth is going to be quite high if you are sending attachments out to all.

In Drupal you could create a Webform template with all of those custom data sets and style it anyway you want. Then you would just need a link in your email to that webform that would autofill the data required.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.