How to add Country in customer Registration Form

I have tried adding customer[country] with no luck or maybe Im missing something?. My alternative is just to use
customer[note][country]

{% form 'create_customer' , return_to:'/pages/distributor-page'  %}
  {{ form.errors | default_errors }}

  
    
    
  

  
    
    
  

  
    
    
  

   
   
  

  
    
    
    

  

  
    
  

  
{% endform %}

Hi @uchizenmarux ,

I checked and you can’t add it directly in register form, if you want you can just add it as a note or have to install app.

Code for note:


Hope it helps!

Thanks for your reply. I tried that btw but I don’t know how to make that a condition so that when the user will log in I can make that as a reference on which design I will provide to him. As far as I know, notes cannot be accessed in liquid.

Hi @uchizenmarux ,

Yes, it seems it doesn’t support to get this. Refer https://shopify.dev/api/liquid/objects/customer

So I recommend you to use the app for it. Refer:

Hope it helps!

1 Like

thanks for your reply. Anyway, I am using tag now because I can access it using liquid.

1 Like

Hi @uchizenmarux ,

Congratulation.

It’s also a way, it’s just that you can’t change it directly at the front end.

Hey @uchizenmarux , as of 2024 you can use new Shopify Flow feature - Admin API call. You can store country as a customer tag (form needs input customer[tags] with comma separated values). In this flow, you need to select customerUpdate and then send mutation https://shopify.dev/docs/api/admin-graphql/2024-01/mutations/customerUpdate