Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more

Compare at price not displaying in storefront api GraphQl

Solved

Compare at price not displaying in storefront api GraphQl

Royw
Shopify Partner
3 0 1

Hi, 

I try to get the compare at prices via the storefront api, but this is not working. It looks like a bug. 
This is what I did: 

 

1. Added compare prices to each variant

2. Get the product query and retrieve the compareAtPrice key

 

Unfortunately, the compare at price returns null. See screenshots.

The displayed result is the raw response from the api. 

 

What could be the reason?

Scherm­afbeelding 2024-10-18 om 08.40.49.pngScherm­afbeelding 2024-10-18 om 09.01.24.png

Accepted Solution (1)

Finer
Shopify Partner
2672 559 933

This is an accepted solution.

@Royw did you check in settings → market → preferences, if the compare price feature is activated? Shopify has changed this recently.

- Did my answer help? Mark my post with a like
- Did I solve your problem? Mark my post as an accepted solution.
- You need professional help? Contact our Shopify Partner Agency

View solution in original post

Replies 2 (2)

Finer
Shopify Partner
2672 559 933

This is an accepted solution.

@Royw did you check in settings → market → preferences, if the compare price feature is activated? Shopify has changed this recently.

- Did my answer help? Mark my post with a like
- Did I solve your problem? Mark my post as an accepted solution.
- You need professional help? Contact our Shopify Partner Agency
Royw
Shopify Partner
3 0 1

Thanks!