Fix 'can't be larger than 64 kilobytes' errors
Have you encountered this error message while working on any pages within Shopify?
Below is a description of why this would occur as well as a work-around to prevent it from happening.
In some rare circumstances, you may run into a situation where your page is larger than 64kb (64 kilobytes). First off, 64kb is a huge amount of textual data. To give some idea of what 64kb really means:
This is not a Shopify imposed limit, rather it is a mySQL database cell limit for TEXT data type. In the rare event that you have a page that must exceed this database limit, don't worry - we have a work around for you.
In this situation, you must break up your data into smaller chunks and create an alternate page template for your special page to "glue" these chunks back together.
You can approach this in one of two ways:
- Use multiple pages to show the content
- Use multiple snippets to show the content.
Either way, the new alternate page template will be used to "glue" your content together.
To get started:
Create either your pages for your content or your snippets and make note of their names – you will need them to use in your template in order to "glue" them back together.
Make a new template based on your page template. If you are unclear on how to do this, please read this page before proceeding.
Once your special template has been created you need to call the broken up content into the template. For pages, your template will look something like this – using the page handles for each of your parts:
If you are using snippets then your page code should look something like this: