Showing Customer Metafields on Customer Account Page

Shopify Partner
27 0 4

Hi just wondering if anyone can help me with customer metafields. 

I have VIP customers that I want to show specific messaging to on the their classic account page. So far I have created a custom metafield definition (ensuring that i selected read storefront) 

I tried this on a test customer account but I am stuck on how to get the metafield information to show to them on their account page. 

Please help!

Replies 2 (2)

1245 113 151
  1. In the theme editor, locate the template file responsible for rendering the customer account page. This file is typically named customers/account.liquid or similar.

  2. Open the customers/account.liquid file and find the section where you want to display the custom messaging for VIP customers.

  3. Within that section, you'll need to add code to fetch and display the custom metafield information for the logged-in customer.

    Here's an example of how you can retrieve and display a specific metafield (assuming you have a metafield named "vip_status"):



{% if customer.metafields.namespace.vip_status %}
  <p>{{ customer.metafields.namespace.vip_status }}</p>
{% endif %}



Shopify Partner
27 0 4

Thanks for that but I did get it to work, however how do I get the meta field to show to URL?