# Tilopay.startPayment()

> Closes the purchase. It takes no parameters; it redirects to the redirect URL or shows 3DS in responseTilopay.

- kind: sdk-method
- status: stable
- sdk_version: 2.1.1
- last_verified: 2026-10-22
- url: https://tilopay.com/en/developers/sdk/reference/startpayment

Closes the purchase started with [`Tilopay.Init()`](/en/developers/sdk/reference/init) (or the card
save started with [`InitTokenize()`](/en/developers/sdk/reference/init-tokenize)).

## Signature [#firma]

```js
await Tilopay.startPayment()
```

It takes no parameters. **It requires the data to be complete**: payment method, card data and
whatever the method needs, sent in `Init()` or in
[`updateOptions()`](/en/developers/sdk/reference/update-options).

## 3DS: the SDK handles it [#tres-ds]

**The SDK handles the whole 3D Secure flow.** If the bank asks for it, the SDK shows it in the
`responseTilopay` container:

```html
<div id="responseTilopay"></div>
```

See [form fields](/en/developers/sdk/campos-del-formulario#campos).

## Where the result arrives [#resultado]

On successful payment, the SDK redirects and the promise resolves with `{ "message": "" }`, without payment data. On error it returns `{ "message": "<description>" }`.

If everything goes well, the SDK redirects to the URL given in `redirect`. That redirect is
received by the customer's browser, so before delivering the product
[confirm the result on your server](/en/developers/sdk#confirmar).

If there is an error, the method returns the description:

```json
{
  "message": "<error description>"
}
```

With SINPE Móvil, until the transfer arrives, `startPayment()` returns the pending-SINPE error.
See [`getSinpeMovil()`](/en/developers/sdk/reference/get-sinpe-movil).
