Localization form Bug: Redirects Metaobject pages to the Metaobject “folder” (drops the Metaobject page handle)

Hi Shopify team,

We’ve found a Markets/localization issue when using the native country selector on Metaobject webpages.

Context

Issue
Using Shopify’s country selector localization form: on a Metaobject webpage (/pages/<folder>/<handle>) redirects to:/<locale>/pages/<folder>

Instead of preserving the full path:/<locale>/pages/<folder>/<handle> (or the equivalent localized URL).

Steps to reproduce

  1. Create/publish a Metaobject webpage at /pages/<folder>/<handle>
  2. Use an official theme with the native country selector (repro’d on Horizon + Dawn)
  3. Open the Metaobject page and switch country → handle is dropped.

Expected: keep /pages/<folder>/<handle>
Actual: redirects to /pages/<folder>

Thanks!

2 Likes

Hi @senabre

Thanks for flagging this issue - digging into this now.

2 Likes

Thank you @Liam-Shopify :slight_smile:

Hi again @senabre - it does look like the issue you’re experiencing with the native country selector on Metaobject pages is a known limitation related to how Shopify handles URL localization and redirects. Connecting with the team to see if there’s any current possible workarounds.

1 Like

Thanks for the update, @Liam-Shopify!

From our side, after testing the usual approaches we know for the localization form, it doesn’t seem like there’s a viable workaround at the moment. Even the return_to input is correct or if you manually adjust it with JS, the redirect still consistently drops the Metaobject handle and sends users to the “folder” URL (/pages/<folder>).

This becomes quite problematic in practice, as that folder URL typically doesn’t correspond to a real page unless the merchant explicitly creates one. In most cases it behaves very similarly to a 404 from a user experience perspective.

Hopefully the team can provide some guidance here :slight_smile:

Thanks again for looking into it!

Thanks @senabre

This limitation is now on the teams radar to address - however there’s no ETA I can share on when this will be supported. Thanks for the additional info on your experiences too - that is helpful context that I’ve added to the case.

2 Likes