Introduction
This guide explains how to translate your Shopify customer account notifications.
The customer account notifications are:
- Customer Account Activation
- Customer Account Welcome
- Customer Password Reset
Please follow the other guide if you want to translate the other notifications like Order Confirmation.
Step 1
Before you are able to translate your customer notifications, you have to make some changes to your theme.
Please insert the following snippet:
<input type="hidden" name="customer[tags]" value="ly#{% assign language = cart.attributes["language"] %}{% if language == nil %}{% assign language = shop.metafields["languages"]["default"] %}{% endif %}{{ language }}ly#"/>
right before each occurrence of {% endform %} in the following templates:
- customers/activate_account.liquid
- customers/login.liquid
- customers/register.liquid
- customers/reset_password.liquid
Here is what your customers/activate_account.liquid should look like afterwards:
Step 2
Navigate to the "Translations / Shop / Customer Notifications" section in langify to open a template that you can use to translate your Shopify customer notifications:
Step 3
Open a Text Editor of your choice and copy over the langify customer notification template:
Step 4
Navigate to the "Settings / Notifications" section in your Shopify backend:
Step 5
Open the customer notification that you'd like to translate and copy the HTML email content:
Step 6
Back in your Text Editor replace the "TEXT FOR ... HERE" with the HTML email content from your Shopify customer notification where ... must match your base language (English in this example):
Step 7
Now replace the other "TEXT FOR ... HERE" occurrences with the HTML email content of your Shopify customer notification and translate it into the corresponding language. In this example, I've replaced "TEXT FOR German HERE" with the original customer notification translated into German (You must not translate any liquid code in between {% %} or {{ }})
Step 8
Finally, after you've replaced every occurrence of "TEXT FOR ... HERE" with the corresponding translations, replace your current Shopify HTML email notification with the content of your Text Editor:
Step 9
Click "Save" to store your new, translated, customer notification.
Your customers should now receive the translated notification matching their currently selected language.
Translating the notification subject:
You can use the very same translation template to translate the subject of your notification.
Simply replace "TEXT FOR ... HERE" with the corresponding subject translation so that you end up with something like:
{% assign language = customer.tags | join: '' | split: 'ly#' %}
{% case language[1] %}
{% when 'ly2315' %}
Aktivierung Ihres Kundenkontos
{% else %}
Customer Account activation
{% endcase %}
Afterwards, replace your Email subject in Shopify with the translation template including your subject translations: