Email Marketing


Loading url as image in Email marketing

Hey all, 

We want to be able to load the image from an image url called from our connected database in our email marketing. Being able to personlize the email further with custom images based on receipiant feels like a good idea to us. Does anyone have any insight as to how I might be able to do that?



2 Replies 2
Recognized Expert | Diamond Partner
Recognized Expert | Diamond Partner

Loading url as image in Email marketing

Hi @Rituul

there are many different ways. I think the easiest one would be a simple custom module with a simple text(not rich-text) for placing the URL into. For this example I've named it "Image url". The code looks like this:

<img src="{{module.image_url}}">


If you'd like to have more options like links, sizing ... you can modify it but keep in mind that it should be inline-css (unless you have custom html email templates)


to add a link, add either a URL or another simple text field to the module and modify the code to this:

{% set href = module.image_link.url.href %}
{% if module.image_link.url.type is equalto "EMAIL_ADDRESS" %}
	{% set href = "mailto:" + href %}
{% endif %}
<a href="{{ href }}" % if module.image_link.open_in_new_tab %}target="_blank"{% endif %} {% if module.image_link.rel %}rel="{{ module.image_link.rel }}"{% endif %}>
	<img src="{{module.image_url}}">


to add sizing simply add at least one number field and modify the code like this

<img src="{{ module.image_url }}" width="{{ module.image_width}}" style="width:{{ module.image_width }}px;">



hope this helps, 




Anton Bujanowski Signature
Community Manager
Community Manager

Loading url as image in Email marketing

Hi @Rituul,


Thank you for reaching out!


I would like to invite our subject matter experts to see if they have any advice.

Hi @NicoleSengers@ThinkLighthouse@Anton - Do you have any insight for @Rituul?

Thank you!




Did you know that the Community is available in other languages?
Join regional conversations by changing your language settings !