Shopify themes, liquid, logos, and UX
I'm trying to make a dynamic button that directs to a product collection. The collection is based off of the metaobject definition, and I"m hoping to make the button a dynamic button that will link to the proper collection of the page. I'm getting this error. Can anyone help me out?
Hey @CoffeeSam,
In Shopify, the "button_link" property typically doesn't support Liquid templating the way you're trying to use it. For dynamic links in Shopify JSON templates, you'll need to use a different approach.
Here are some solutions to try:
If you're working in a JSON template file, try using the url_for_type Liquid filter. Replace your current line with something like:
"button_link": "{{ metaobject.name.value | handleize | prepend: '/collections/' }}"
Another approach is to use a URL object format that Shopify supports:
"button_link": "{{ routes.collections_url }}/{{ metaobject.name.value | handleize }}"
If you're building a section schema, you might need to set up a proper link picker instead of directly embedding Liquid in the JSON:
"button_link_field": { "type": "url", "label": "Button Link", "default": "/collections/all" }
And then reference that field elsewhere.
If your specific button component doesn't support dynamic values through Liquid, you may need to create a custom block or section that can handle this dynamically on the server-side.
Shopify's JSON templates have specific requirements for how dynamic values are passed. The error suggests that the "partial" application type isn't supported for button links, which makes sense because Shopify expects complete URLs for navigation elements.
Feel free to reach out over email if you need any more help 🙂
Cheers!
Shubham | Untechnickle
Helping for free: hello@untechnickle.com
Don't forget to say thanks, it'll make my day - just send me an email!
Get Revize for Free | Let your shoppers edit orders post-purchase | Get Zero Support Tickets | #1 Order Editing + Upsell App
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025