> For the complete documentation index, see [llms.txt](https://help.accentuate.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.accentuate.io/use-case-guides/food-and-beverage/nutritional-values-metafield.md).

# Nutritional Values Metafield

### Prerequisites

Before you begin, make sure you have:

* An active Shopify store
* Accentuate Custom Fields installed from the Shopify App Store
* Staff permissions to access Apps in your Shopify admin
* (Recommended) An Online Store 2.0 theme, which allows metafield values to be displayed via the theme editor without touching code

***

### Key Concepts to Know First

Scope — The Shopify object the metafield attaches to. For Nutritional Values, this will be Products.

Namespace & Key — The unique identifier for your field. The namespace groups related fields (e.g. custom) and the key is the specific field name (e.g. nutritional\_values). Together they form custom.nutritional\_values, which is the address used in your theme to pull the value.

Field Data Type — Controls what kind of data the field holds. For Nutritional Values, a Multi-line text field is recommended. Nutritional information is detailed and product-specific — it includes calories, macronutrients (protein, carbs, fat), micronutrients (vitamins, minerals), fibre, and often per-serving and per-100g values. A free-text field allows your team to document complete nutritional information for each product without being restricted to predefined options. If you want to support formatting such as a table layout or headers, choose Rich Text instead.

***

### Step-by-Step Guide

Step 1 — Open ACF from your Shopify Admin Go to your Shopify Admin, click Apps in the left sidebar, and open Accentuate Custom Fields. You'll land on the ACF dashboard, which shows the Metafields and metaobjects section with cards for Products, Shops, Metaobjects, and Customers.

Step 2 — Open Product Metafields In the Products card, click the Metafields button. This takes you into the Product Custom Fields screen where you can see all existing fields listed with their types and manage your definitions.

Step 3 — Add a New Section Click the + Add section button in the top-right area of the Product Custom Fields screen. An Add Section modal will open across two pages.

Page 1 — Basic Details:

* Title: Nutritional Values — displayed in bold as a visual header when editing product values (1–50 characters, no HTML)
* Name: nutritional\_values — must be unique within your Product fields (3–64 characters, letters, digits, underscores or dashes only)
* Description: Optionally add a note like Complete nutritional information including calories, macronutrients, and micronutrients per serving and per 100g — supports Markdown
* Color: Leave as the default #dfe3e8, or choose a colour to visually distinguish this section from others in your Food & Beverage field setup
* All fields in this section apply to: Leave as All types unless you want to restrict this to specific product types
* Make visible to the Storefront API: Leave checked (default) — this makes the nutritional information accessible in themes and custom storefronts

Click Next to continue.

Page 2 — Advanced Settings:

* Repeatable section: Leave unchecked — nutritional values are a single block of information per product, not a repeating block.
* Include value of first text field: Optionally check this — since the field is a text field, showing a preview of calorie content in the section header when collapsed can help your team quickly identify nutrition info when scanning products.
* Show as collapsed when editing: Optionally check this — nutritional information can be lengthy, so collapsing the section by default keeps the product edit page tidy. Editors can expand it when needed.
* Hide section: Leave unchecked — checking this would make the section invisible in the editor entirely.
* Show section even if empty: Optionally check this if you want the Nutritional Values section to always appear on products, even before nutrition information has been added.
* Exclude from layout: Leave unchecked — only tick this if you want the section excluded from ACF's layout editing tools.

Click Done to save the section.

Step 4 — Add the Nutritional Values Field Once the section is saved, click + Add field to add the actual field inside it. Fill in the details:

* Label: Nutritional Values
* Namespace: accentuate (ACF's default, or use your own e.g. food)
* Key: nutritional\_values
* Field Data Type: Select Multi-line text — this gives your team a spacious text area to document complete nutritional information per product. If you want to support formatting such as a table layout with headers for "Per Serving" and "Per 100g", choose Rich Text instead.

Step 5 — Save Click Save. Your Nutritional Values field will now appear inside its section on every product edit page in your Shopify admin, giving your team a dedicated space to enter complete nutritional information for each product.

***

### Populating Nutritional Values

One by one: Open any product in Shopify Admin, scroll to the Nutritional Values section added by ACF, type or paste the complete nutritional information into the text area, and save. This is the most practical method since every product's nutrition is unique and must be verified against the product label or manufacturer data.

CSV import: Use the Export button to download a CSV template, fill in the nutritional\_values column for each product row, then re-import via the Import button. This is useful when migrating nutrition data from an existing product database or supplier nutritional information.

***

### Displaying Nutritional Values on Your Storefront

Theme Editor (no code, OS 2.0 themes): Go to Online Store → Themes → Customize. Open a product template, click Add Block, select an ACF or Metafield block, choose the Nutritional Values field, position it on the page (typically in a Nutrition Facts or Nutritional Information section, or inside a collapsible accordion), and save. It will display automatically for any product with nutritional information documented.

Liquid Code (all themes): Add this to your product template file where you want the nutritional information to appear:

For Multi-line text:

`{% if product.metafields.custom.nutritional_values %}`

&#x20; `<div class="nutritional-values">`

&#x20;   `<strong>Nutritional Information:</strong>`

&#x20;   `<p>{{ product.metafields.custom.nutritional_values.value }}</p>`

&#x20; `</div>`

`{% endif %}`

For Rich Text:

`{% if product.metafields.custom.nutritional_values %}`

&#x20; `<div class="nutritional-values">`

&#x20;   `<strong>Nutritional Information:</strong>`

&#x20;   `{{ product.metafields.custom.nutritional_values.value }}`

&#x20; `</div>`

`{% endif %}`

If you used a custom namespace (e.g. food), replace custom with your namespace name.

***

### Tips & Best Practices

* Always copy from the product label or manufacturer data — nutritional information is regulated and must be accurate. Never estimate or calculate nutrition values yourself. Always source from official product labels, nutritional databases provided by suppliers, or manufacturer documentation.
* Include both per-serving and per-100g values — different customers want to see nutrition different ways. Include both: "Per Serving (30g): 150 calories. Per 100g: 500 calories".
* Be clear about serving size — always define what a "serving" is: "Serving Size: 1 cup (240g)", "Per 100ml", "Per 2 tablespoons (32g)". Ambiguous serving sizes create confusion.
* Include all major nutritional components — depending on regulatory requirements in your market, include:
* Calories (energy)
* Total Fat (with breakdown: saturated, trans, unsaturated)
* Cholesterol
* Sodium
* Total Carbohydrates (with breakdown: fibre, sugars)
* Protein
* Vitamins (A, C, D, B vitamins, etc.)
* Minerals (calcium, iron, potassium, etc.)
* Any other significant nutrients
* Use consistent units — decide on standard units (grams, milligrams, international units) and apply them uniformly: "Protein: 8g", "Sodium: 200mg", "Vitamin D: 400 IU".
* Use Rich Text for complex nutrition tables — if nutritional information is detailed with many nutrients, use Rich Text to format it as a table or with headers for better readability. For example:
* Per Serving (1 cup):
* Calories: 150
* Protein: 8g
* Total Fat: 5g
* Carbohydrates: 20g
* Per 100g:
* Calories: 125
* Protein: 6.7g
* Include percentage Daily Value (%DV) if relevant — in many markets, including %DV helps customers understand nutritional context: "Protein: 8g (16% DV)", "Iron: 2mg (11% DV)".
* Note if nutrition changes based on preparation — if cooking or preparation significantly changes nutrition, document both: "As Packaged: 200 calories. After Cooking: 150 calories".
* Include allergen information if relevant — if nutrition information contains allergen-related details, include them: "Contains: Milk proteins, soy lecithin".
* Update when formulations change — if a supplier changes ingredient sourcing or formulation, nutrition values may change. Update this field immediately when informed of changes.
* Keep a master nutrition database — maintain an internal document with approved nutritional information for each product, sourced from official labels or supplier data. Use this as your source of truth.
* Be compliant with regulations — nutritional labeling is heavily regulated. Ensure your nutritional information complies with local requirements (FDA Nutrition Facts Label in the US, Nutrition Information Panel in Canada/Australia, etc.).
* Include rounding information if relevant — some nutrients may be rounded to zero on labels but present in small amounts: "Contains less than 0.5g trans fat (rounded to 0g on label)".
* Pair with Ingredients and Dietary Tags — display Nutritional Values alongside Ingredients and Dietary Tags on the product page. Together they give customers complete understanding of what's in the product.
* Avoid the shopify namespace — it is reserved by Shopify and can cause conflicts. Use custom or a brand-specific name like food.
* Multi-language stores — ACF supports translatable metafields. Mark Nutritional Values as translatable if you serve markets where nutrition labeling conventions or nutrient names differ by region (e.g., different names for B vitamins in different languages).

***

### Quick Reference

| Setting          | Value                                                                         |
| ---------------- | ----------------------------------------------------------------------------- |
| Scope            | Products                                                                      |
| Section Title    | Nutritional Values                                                            |
| Section Name     | nutritional\_values                                                           |
| Field Label      | Nutritional Values                                                            |
| Namespace        | custom                                                                        |
| Key              | nutritional\_values                                                           |
| Full Identifier  | custom.nutritional\_values                                                    |
| Field Data Type  | Multi-line text (or Rich Text for formatted nutrition tables)                 |
| Storefront API   | Enabled (checked by default)                                                  |
| Liquid Reference | {{ product.metafields.custom.nutritional\_values.value }}                     |
| Critical         | Always copy from product label or manufacturer data; never calculate yourself |
| Best Practice    | Include both per-serving and per-100g values                                  |
| Best Practice    | Be explicit about serving size definition                                     |
| Best Practice    | Use Rich Text with headers or tables for complex nutrition information        |
| Compliance       | Ensure compliance with local nutrition labeling regulations                   |

***

For further details, visit the official ACF documentation at help.accentuate.io

<br>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.accentuate.io/use-case-guides/food-and-beverage/nutritional-values-metafield.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
