Custom field
You can collect additional customer information or block checkout with the custom field Checkout Block. Custom fields can be required or option and support a variety of input types including text, dropdown, checkbox, date picker, birthday, and more.
Save custom fields to order
All custom fields will save to the order as either an order metafield, order attribute, or the order note. We recommend using order metafields when possible as they are the most robust way of storing and retrieving custom data on orders within Shopify.
Order metafields
When saving custom fields to order metafields, the namespace using is checkoutblocks and the key is defined when you add a custom field to the block:
Metafield Definitions
You can optionally create metafield definitions to surface specific custom fields directly on the order detail page. Here's a quick tutorial on creating a metafield definition for custom fields:
Order notes
When saving custom fields to order notes, any existing content is completely replaced with your custom field. A benefit of using the order notes type is that it will show existing order notes entered in the cart within checkout automatically. This ensure consistency across the checkout funnel for specific use cases such as order notes or delivery notes. Order notes are incompatible with draft orders.
Order attributes
When saving to order attributes (also known as note attributes or cart attributes), it's important to note they are incompatible with:
- Shopify's native packing slips
- Draft orders
If you need to support any of the above, we recommend using order metafields.
Adding Custom Fields into Existing Forms
At this time, Shopify does not support adding new fields into existing forms such as shipping address or billing address. Instead, we support adding custom fields above or below these forms.
Filtering orders by custom field
You can setup a Shopify Flow workflow to tag orders on creation based on the custom field value being present so that you can filter orders more easily within Shopify. Here's a sample Shopify Flow workflow to get started: https://cdn.shopify.com/s/files/1/0728/3241/8071/files/Tag_orders_that_have_agreed_to_terms.flow?v=1698702164