Hello Friend,
How to add extra field other than SKU and barcode UPC on Shopify admin platform (Product editing page)?
Currently, I have multiple suppliers, and all have various SKU, they have same VPN ( Vendor Product Number/Vendor Stock Code) and also there is barcode (UPC) as well.
How to create third field other then two showing on product editing page for inventory?
1 ) SKU, 2) Barcode (ISBN, UPC, GTIN, etc.) , want to create third for VPN - Don’t want all details to be displayed on live website
Thanks
Hi there,
to add an extra field for VPN or any other custom information in Shopify, you’ll need to use metafields.
Metafields allow you to add additional data to Shopify objects like products, orders, and customers.
Here’s how you can add a custom metafield for VPN on your Shopify store:
Step 1: Define the Metafield
- Log in to your Shopify admin;
- Go to ‘settings’ from the bottom left of the Shopify admin panel;
- Select ‘metafields’ (under the Custom data section);
- Choose ‘products’ to add a metafield to products specifically;
- Click ‘Add definition’ to create a new metafield;
- Enter a name for the metafield, such as “VPN” or “Vendor Product Number”;
- Select the content type. For a VPN, you might choose ‘Single line text’ or ‘Multi-line text’, depending on your needs;
- Optionally, add a description to help identify what this metafield is used for;
- Click Save to create the metafield definition.
Step 2: Add Metafield Values to Products
- Go to ‘products’ in your Shopify admin;
- Select a product to which you want to add the VPN;
- Scroll down to the ‘metafields’ section (usually found at the bottom of the product details page);
- Enter the VPN value for the product in the new metafield you created;
- Click Save to update the product with the new metafield value.
Step 3: Optionally Display Metafields (If Needed)
Since you mentioned that you don’t want this information to be displayed on the live website, you can skip this step.
However, if you later decide you want to display this information on your storefront, you can modify your theme’s code to include metafields:
-
Go to Online Store and then ‘themes’ in your Shopify admin;
-
Click ‘actions’ next to your active theme and select ‘edit code’;
-
Find the appropriate template file where you want to display the VPN (e.g., product.liquid);
-
Insert the following Liquid code to display the metafield value:
{% if product.metafields.custom_fields.vpn %}
<p>VPN: {{ product.metafields.custom_fields.vpn }}</p>
{% endif %}
-
Adjust custom_fields to match the namespace you used when creating the metafield, and vpn to match the key;
-
Click Save to apply the changes.
This setup allows you to store and manage additional product information without affecting your live website’s layout, giving you flexibility to use or display this information as needed.
Let me know if this helps or if you need further assistance!
Since the SKU and Barcode fields are attached to the variant, you might want to use Variant Metafields in this case for consistency.
You can do this via the Shopify Admin > Settings > Custom data. Under the “Metafield definitions” section, select “Variants”, then “Add definition”. You can pin the metafield to the variant editing page.
For example: