{% comment %}

The {% comment %} tag prevents anything inside it from being executed or output. It is primarily used for one of two purposes:

  1. For a developer to leave notes behind so that when they or another developer looks at the code later they understand what it is doing.
  2. To temporarily "remove" a block of code from a template so that it is no longer evaluated but is easy to add back later. This is particularly helpful when troubleshooting a template error.

Syntax

{% comment %}...{% endcomment %}

Examples

Liquid Comment

Copy
{% comment %}

This text will not be output

{% endcomment %}