Skip to main content
Question

Embed Instagram feed to emails - widgets

  • November 26, 2025
  • 1 reply
  • 8 views

Forum|alt.badge.img

I have embedded the instagram feed for our store to email template, however the posts are different sizes depending on whether content is a real, photo etc. I also want the posts to be centred which they aren’t.

I want the images to appear uniform, like they do under WIDGET tab in rss.

How can I achieve this?

This is the KLAVIO code we used:

<div>{% for item in feeds.FEED_NAME.rss.channel.item|slice:":3" %}
<table style="display:inline-block; margin-left:auto; margin-right:auto">
<tbody>
<tr>
<td style="width:150px; text-align: center;"><a href="{{ item.link }}">
<img style="max-width: 150px; height: auto;" src="{% if item|lookup:'media:content'|lookup:'0'|lookup:'@url' %}{{ item|lookup:'media:content'|lookup:'0'|lookup:'@url' }}{% else %}{{ item|lookup:'media:content'|lookup:'@url' }}{% endif %}" style="margin: 1px; max-width: 150px; height: auto;" /></a>
</td>
</tr>
</tbody>
</table>
{% endfor %}</div>

 

1 reply

talha.hussain
Problem Solver II
Forum|alt.badge.img+4
  • Problem Solver II
  • November 26, 2025

Use a fixed-size square background image instead of <img> tags. That’s the only email-safe way to make all Instagram posts look uniform.

Replace your image cell with this:

 

{% set img = item|lookup:'media:content'|lookup:'0'|lookup:'@url' or item|lookup:'media:content'|lookup:'@url' %} <table align="center" style="display:inline-block; margin:0 auto;"> <tr> <td width="150" height="150" style="background:url('{{ img }}') center/cover no-repeat; width:150px; height:150px;"> <a href="{{ item.link }}" style="display:block; width:150px; height:150px;"></a> </td> </tr> </table>

✔ Makes all posts the same size
✔ Centers them
✔ Works in major email clients