Skip to main content
Solved

Empty address fields showing as “None” in order confirmation email

  • July 15, 2026
  • 2 replies
  • 67 views

Lucia937
Active Contributor IV
Forum|alt.badge.img+6

Hi everyone,

I’m having an issue with my Klaviyo order confirmation email. When a customer leaves one of the address fields empty, the email displays “None” instead of simply hiding the empty field.

Has anyone experienced this before? Is there a way to adjust the template code so empty address fields are not shown at all?

Thank you!

 

p.s. I tried editing the tags manually and adding a default empty value ('') to one of them to test, but this then affects the other address tags as well, (like first name and last name). Interestingly, it also seems to break the block displaying the order summary.

I used a klaviyo order confirmation flow email template. This is what Klaviyo AI tells me. (But it didn’t offer any solution excep for going into the code )

 

Best answer by GabbyEsposito

@Lucia937 hi there,

Yes, this usually happens when that address field is coming through with no value, or with a placeholder like None, and the template is rendering it directly.

The safest fix is to leave the order summary table alone and only update the text block that contains the shipping address. In that text block, open the Source code view and wrap any optional field in a conditional so it only shows if there’s actually data there.

For example, for address line 2 you could use:

{% if event.ShippingAddress.address2 and event.ShippingAddress.address2 != "None" %}
{{ event.ShippingAddress.address2 }}
{% endif %}

You can repeat that pattern for any optional address field, like company, state/province, or address line 2.

A couple of watchouts:

  • Make the change only in the address text block, not in the dynamic order summary block, since that block depends on its row collection/alias setup to render line items correctly.

  • If the condition seems to disappear in the visual editor, that’s expected. Conditional tags are still present in Source code even when they don’t show inline.

  • It’s worth checking Preview & Test using the flow event to confirm whether that field is truly blank or whether the integration is passing the literal value "None".

If it helps, I’d start by testing just one field like address line 2 first, then apply the same pattern to the other optional lines once that works.

2 replies

GabbyEsposito
Community Manager
Forum|alt.badge.img+15
  • Community Manager
  • Answer
  • July 17, 2026

@Lucia937 hi there,

Yes, this usually happens when that address field is coming through with no value, or with a placeholder like None, and the template is rendering it directly.

The safest fix is to leave the order summary table alone and only update the text block that contains the shipping address. In that text block, open the Source code view and wrap any optional field in a conditional so it only shows if there’s actually data there.

For example, for address line 2 you could use:

{% if event.ShippingAddress.address2 and event.ShippingAddress.address2 != "None" %}
{{ event.ShippingAddress.address2 }}
{% endif %}

You can repeat that pattern for any optional address field, like company, state/province, or address line 2.

A couple of watchouts:

  • Make the change only in the address text block, not in the dynamic order summary block, since that block depends on its row collection/alias setup to render line items correctly.

  • If the condition seems to disappear in the visual editor, that’s expected. Conditional tags are still present in Source code even when they don’t show inline.

  • It’s worth checking Preview & Test using the flow event to confirm whether that field is truly blank or whether the integration is passing the literal value "None".

If it helps, I’d start by testing just one field like address line 2 first, then apply the same pattern to the other optional lines once that works.


Fabi.SPL
Contributor I
  • Contributor I
  • July 19, 2026

klaviyo's default template treats those address fields as required strings, so when they're empty it literally renders the python None object. the klaviyo ai suggestion is basically useless for this.

the actual fix is a conditional block around each address line. wrap the field in {% if address.line1 %} tags, same for city, state, zip. but here's the gotcha - if you chain conditionals wrong, it'll also hide the whole address block when one field is missing. you want to check each line individually, not the whole address object.

your test with the empty string likely broke things because you were modifying the variable itself, which cascaded. the conditionals need to be pure checks on the original variable, not assignments.

want me to write out the exact snippet that works for this? i've fixed this exact layout issue in klaviyo templates before.