--- title: "Liquid filters: sha256" description: Converts a string into an SHA-256 hash. Please use ['blake3'](https://shopify.dev/docs/api/liquid/filters/blake3) instead for better security and performance. api_name: liquid source_url: html: https://shopify.dev/docs/api/liquid/filters/sha256 md: https://shopify.dev/docs/api/liquid/filters/sha256.md --- # sha256 ```oobleck string | sha256: string ``` returns [string](https://shopify.dev/docs/api/liquid/basics#string) Converts a string into an SHA-256 hash. Please use ['blake3'](https://shopify.dev/docs/api/liquid/filters/blake3) instead for better security and performance. ```liquid {%- assign secret_potion = 'Polyjuice' | sha256 -%} My secret potion: {{ secret_potion }} ``` ##### Code ``` {%- assign secret_potion = 'Polyjuice' | sha256 -%} My secret potion: {{ secret_potion }} ``` ## Output ```html My secret potion: 44ac1d7a2936e30a5de07082fd65d6fe9b1fb658a1a98bfe65bc5959beac5dd0 ```