Metafield character limit is a problem. Any alternatives?

Topic summary

Main issue: Variant metafields need to store values larger than the 65,536 character limit for use cases like vehicle fitment lists spanning hundreds of vehicles.

Guidance from Metafields team:

  • Prefer JSON metafield type for large structured data; supports up to 2,000,000 characters.
  • Alternative is the string type; supports up to 5,000,000 characters but has no definition support.
  • String type is not being phased out.

Clarifications provided:

  • 2M refers to 2 million characters (characters, not megabytes).

Outcome: Practical workarounds identified (JSON or string metafields) that exceed the original limit. No further action items noted; questions about limits and deprecation were answered. Status appears resolved.

Summarized with AI on January 20. AI used: gpt-5.

We need to store data into variant metafields that can be longer than 65,536 character limit.

Is there any alternative or workaround to do so ?

1 Like

What are you storing that would require more than that? Knowing this context is helping for discussing other approaches.

Our largest data field stores vehicle filtment data. We store information before the vehicles that are compatible with the given part the visitor is looking at which could be hundreds of vehicles.

Hi there,

I’m Katherine from the Metafields team. The best workaround would be to structure the data as json, and then use a json type metafield, which allows up to 2M characters. Alternatively if json isn’t an option, you can use the string type, however note that there’s no definition support for the string type.

2 Likes

Thx , Those are great options thank you. Two questions:

  1. What is the length limit for String type metafields ?
  2. Isn’t String type being fazed out ?

The length limit is 5M characters.

We have no current plans to phase out the string type.

Hi KathB -

Just so I understand this message correctly.

Can I confirm that the 2M characters is 2 million characters?

Looking forward to your feedback, thanks a lot.

1 Like

@KathB 2M or 5M?

M => megabytes or characters ?

Yes, 2 million characters.