Log in or create an account
If you have an account with us, please log in.

You have no items in your shopping cart.

Frequently Asked Questions

How can we help you?

banner image

How to add custom registration fields to Magento 2?

Such an element as custom registration fields is a tool for learning your audience. But it's important to remember that not everyone likes to sit and enter a lot of information at the registration stage. It can be time-consuming. Therefore, you need to make this process user-friendly.

Adding new fields to the registration in Magento 2 is a technically complex process that requires knowledge of the code. With the Custom Registration Fields extension, you can create new fields without writing a line of code. It provides an opportunity to create a personalized registration stage by using relations between fields and collect all the necessary user information.

To add a custom attribute in the customer registration form in Magento 2, follow these steps:

Step 1. First of all, you need to go to Stores > Configuration > Customer Attributes.

Here you will see 2 options available:

  1. Set Display Customer Attributes on the 'selected customer' option to Yes to make the attributes visible from the backend when selecting a customer during the order creation.
  2. Allow customers to change their group option lets customers choose and change their customer group. To make the option work, create a customer attribute of the Customer Group Selector input type:

customer attributes

Step 2. Now you need to set up the attribute.

Follow this way to do it: Customers > Customer Attributes > Manage Attributes. On this grid, you can set new attributes and customize the already created ones. Then click Add New Attribute to add an attribute:

manage attributes

Step 3. On the attribute configuration step, you will need to fill in several lines.

First of all, you are to fill in such Attribute Properties as:

  • Default Label/ Attribute Code, which specifies an attribute label and a code. 
  • The Store View section provides you an opportunity to select the store view for which the attribute will be accessible
  • And Catalog Input Type for Store Owner field consists of several options, which you choose depending on your specific needs. The following fields will depend on the selection here.

Let it be Text Field, for example.

Then you will see the Default Value line, which defines the preselected by a default value if necessary, and the Values Required line, which consists of yes and no options. If you choose yes, then customers won’t be able to leave this attribute field blank while getting registered.

And the last line in the Attribute Properties section is Input Validation. It specifies the type of input validation.

attribute properties

Step 4. On this step, you have to choose yes or no on the Attribute Configuration options and define a Sorting Order(the order to display a field on the frontend). You can see these options on the screenshot:

attribute configuration

This extension synergizes perfectly with the Custom Checkout Fields extension. Working together, these extensions will improve your store's user experience and help you gather the information you need to grow your business.

Rate the answer?

Total rating: 5.0

If you didn’t find the answer on your question, please, ask here:

Back to top