escape - Liquid Filter Reference
On this page
Description
Escapes a string by replacing characters with escape sequences (so that the string can be used in a URL, for example). It doesn’t change strings that don’t have anything to escape.
| Property | Value |
|---|---|
| Return Type | string |
| Category | text |
Examples
```liquid
{{ “Click ‘Add to Cart’ when you’re ready to purchase” | escape }} ```
Output: Click 'Add to Cart' when you're ready to purchase
```liquid
{{ “Nothing to see here” | escape }} ```
Output: Nothing to see here
Was this article helpful?
Thanks for your feedback! It helps us improve our docs.