---
updatedAt: 2026-05-28T15:28:12.000Z
agentTools:
  projectIndex: https://docs.dlocal.com/llms.txt
---

# Including dlocal.js

Learn how to integrate and use dLocal.js.

To use dLocal.js, include the library and set up your [API credentials](https://docs.dlocal.com/docs/get-api-credentials).

# Include the library

Include this script on your pages to get started—it should always be loaded directly from <https://js.dlocal.com.>

For testing purposes, you can use <https://js-sandbox.dlocal.com>.

```php
<script src="https://js.dlocal.com/"></script>
```

# Using Subresource Integrity (SRI)

We strongly advise implementing [Subresource Integrity (SRI)](https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity)  to protect against potential tampering or unauthorized modifications. This security measure ensures that the content being fetched remains unaltered by external threats.

## Include SRI hash

To apply SRI, include an `integrity` attribute within your `<script>` element.

| Version | Script                                                      | Integrity                                                               |
| :------ | :---------------------------------------------------------- | :---------------------------------------------------------------------- |
| 6.5.0   | <https://static.dlocal.com/modules/fields/6.5.0/parent.js>  | sha384-XyPv8k4n+vVY8J1yZOXR4gV60nGOcvqNcRjdCXCAA3dYDYPW5BKZ0KZRulHyQWA0 |
| 6.7.2   | <https://static.dlocal.com/modules/fields/6.7.2/parent.js>  | sha384-UEecMMFI22Cc05A6KHFsReCsua9SDhCE+ySoAg//Xck9QVN3OTjc9A1wnhi3ebvl |
| 6.8.3   | <https://static.dlocal.com/modules/fields/6.8.3/parent.js>  | sha384-b0AKL9220+ASaGePeYXyuYr9BFPCN3ou6T87ZUoZ0qkWOapECqBzFoyJ2mUQ3uAJ |
| 6.9.13  | <https://static.dlocal.com/modules/fields/6.9.13/parent.js> | sha384-3S3C9jK44rPMwqB5oeA2k9RdQhjLbLnsHzrlSM2QSnUpXJ2ZVtQl8GUmtFr9jxxS |
| 6.9.14  | <https://static.dlocal.com/modules/fields/6.9.14/parent.js> | sha384-9C4ugo26Uf4nZQ0Y7alyY3mnMTJGPLnMn/GC+aiD3XonHx5A3FlTiRb08UWJvmcU |
| 6.9.15  | <https://static.dlocal.com/modules/fields/6.9.15/parent.js> | sha384-Vb2fKhtXKTDFayV5mqrdInso1gOdEDNwi+23FXzpGkRIHIhJsn+X7qEo55yCmpNc |
| 6.9.17  | <https://static.dlocal.com/modules/fields/6.9.17/parent.js> | sha384-tTTdYzrrFNmevqG/2AnVrwryY0ryGXMOrwQVQmkTeQffpfkOqRCVlc2y6qf7M9hL |
| 6.10.0  | <https://static.dlocal.com/modules/fields/6.10.0/parent.js> | sha384-qyEPFO9NDLpCD9H1v5jz9qhHwQSWfBXc6pEe7A5gfacSPrCrkWgXSGrhkXvA8wLp |
| 6.11.0  | <https://static.dlocal.com/modules/fields/6.11.0/parent.js> | sha384-fJU7EYBsbrccZETSHQPfizz6phyfoDzNOhaU13W/1pgsg1wGv7C3X318c3haoLqE |
| 6.12.1  | <https://static.dlocal.com/modules/fields/6.12.1/parent.js> | sha384-PgU3NqOCr1yb8BLETs1cCdN8bbGaIQue3RwHN3Dhq40EneFJvgeZ/orR1j5hwRQj |
| 6.12.3  | <https://static.dlocal.com/modules/fields/6.12.3/parent.js> | sha384-Xczn+pl9z2EqJWXPE4ZmE7UWpupNkabR4PlU5wNZ88DfzAOfryRQ5tBnY6cigNJW |
| 6.13.6  | <https://static.dlocal.com/modules/fields/6.13.6/parent.js> | sha384-vQ4/OGAdZz2rcmMjxlnht3fBvWx19GXJ9fTTVB6flRZEbGUYyI1TYkS8bN84fpMS |
| 6.16.1  | <https://static.dlocal.com/modules/fields/6.16.1/parent.js> | sha384-L7eYGZe4layBmO8mi1b0HzOH6gSoVjZATQ0+6lnnkpTpC6Z5zp8nRzhiRx1xZ0zF |

Here’s an example of how to securely reference version 6.5.0:

```php
<script src="https://static.dlocal.com/modules/fields/6.5.0/parent.js" integrity="sha384-XyPv8k4n+vVY8J1yZOXR4gV60nGOcvqNcRjdCXCAA3dYDYPW5BKZ0KZRulHyQWA0" crossorigin="anonymous"></script>
```