---
title: "money_with_currency"

doc_type: static
doc_category: static
doc_version: v20270301
source_url:
  html: 'https://developer.shopline.com/docs/sline/filter/money-with-currency'
  md: 'https://developer.shopline.com/docs/sline/filter/money-with-currency.md'
---

# money_with_currency


    Formats a given price based on the store's currency format setting - Format with currency code (refer to [Setting Up Custom Currency Formats for Your Store](https://help.shopline.com/hc/en-001/articles/9855624643865-Setting-Up-Custom-Currency-Formats-for-Your-Store)).

    



    
`{{ price | money_with_currency() }}` returns a string.
    



    
        ## Required params

        
             `price` `integer`, `float`\: The amount.
        
    



    
        ## Optional params

        
            - `code` `string`\: The currency code, which defaults to the currency code of the primary market.
        
            - `currency` [`currency`](https://developer.shopline.com/docs/sline/object/currency.md)\: The currency information, such as `iso_code`, `name` and `symbol`.
        
    



    
## Examples

        
            ### Default

            

            

            
<SlineExample path={'/product/product-1'} objects={ 
    [""] 
}>
```sline
{{{ 10000 | money_with_currency() }}}
```
</SlineExample>
            
        
            ### With the `code` parameter

            

            

            
<SlineExample path={'/product/product-1'} objects={ 
    [""] 
}>
```sline
{{{ 10000 | money_with_currency(code="USD") }}}
```
</SlineExample>
            
        
    
