---
schema_version: "1"
id: fbce031122ce61c4b41864a86d8a66322698b5900eb4b0c7170117e8e547cf8a
title: ispayment Element
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/commerce-cloud/b2c-commerce/guides/isml/b2c-ispayment.md
canonical_url: https://developer.salesforce.com/docs/commerce/pwa-kit-managed-runtime/guide/b2c-ispayment.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 16f0834456c10f7762f1343646e69caa165d43f5d4150d2f17c49cc5691bff8b
products:
  - Composable Storefront
  - Salesforce APIs
---
# ispayment Element

Inject code to render payment methods or express checkout buttons that let a shopper pay for their current basket.

To render express checkout buttons that lets a shopper buy a specific product, see [\<isbuynow>](https://developer.salesforce.com/docs/commerce/pwa-kit-managed-runtime/guide/b2c-isbuynow.md).

`<ispayment>` is only used with B2C Commerce Payments. An associated payments account must be successfully enabled and configured for use on the storefront site where this element appears.

## Syntax

```
<ispayments  payment-request = SalesforcePaymentRequest expression \\required
></ispayments>
```

- payment-request = SalesforcePaymentRequest expression

  - : Specify a `dw.extensions.payments.SalesforcePaymentRequest` as part of an expression for the tag. See [SalesforcePaymentRequest](https://salesforcecommercecloud.github.io/b2c-dev-doc/docs/current/scriptapi/html/api/class_dw_extensions_payments_SalesforcePaymentRequest.html).

## Purpose

The `<ispayment>` tag injects `<script>` code in the page to render payment methods or express checkout buttons that let a shopper pay for their current basket. See [dw.extensions.payments](https://salesforcecommercecloud.github.io/b2c-dev-doc/docs/current/scriptapi/html/api/package_dw_extensions_payments.html) to configure the payment methods and express checkout buttons, as well as understand how they're rendered.

## Rules of Use

This tag appears multiple times on the same page with no limit. When used to render payment methods for the payment step of a checkout page, it only appears once. The tag must be placed where \<script> tags are valid, after the closing \</head> tag in the HTML page.

This tag can't be used in a cached template because it's used for the shopper to pay for their current basket. However, you can use it in a remote included template referenced by a cached template, similar to a minicart.

Payment methods are only rendered when applicable for the basket. If a potentially available payment method doesn't support the basket currency, it isn't presented.

Express checkout buttons are only rendered when applicable for the shopper. If the shopper isn't using a supported device or operating system, or hasn't configured them to use the available express checkout buttons, then no button is presented.

## Example

In this example, `<script>` code is injected by `<ispayment>` to render all payment methods and express checkout buttons that are configured with Salesforce Payments on the site. The ID of the component is “payment” and the CSS class name where the component is to be rendered is “payment-element”.

**note:** The B2C Commerce script code that creates the `SalesforcePaymentRequest` object can be placed in a controller. `<isscript>` is used here as an example.

```
<isscript>
var SalesforcePaymentRequest = require('dw/extensions/payments/SalesforcePaymentRequest');
var paymentRequest = new SalesforcePaymentRequest('payment', '.payment-element');
</isscript>

<ispayment payment-request="${paymentRequest}"></ispayment>
```
