> For the complete documentation index, see [llms.txt](https://mariadb.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mariadb.com/docs/connectors/mariadb-connector-nodejs/mariadb-connector-node-js-guide.md).

# About MariaDB Connector/Node.js

{% hint style="info" %}

<p align="center">The most recent release of <a href="/spaces/CjGYMsT2MVP4nd3IyW2L/pages/WmpaptiE3kKy2mNO6ps0">MariaDB Connector/Node.js</a> is: <a href="/spaces/aEnK0ZXmUbJzqQrTjFyb/pages/r2pMUZbAXRLBlqvRUjpX"><strong>3.5.3</strong></a></p>

<p align="center"><a href="https://mariadb.com/downloads/connectors/connectors-data-access/nodejs-connector" class="button primary">Download Connector/Node.js 3.5.3</a></p>
{% endhint %}

<p align="center"><a href="/spaces/aEnK0ZXmUbJzqQrTjFyb/pages/LPZh9DdMcVtgTnT96JZl">See all MariaDB Connector/Node.js releases</a></p>

<p align="center"><a href="https://mariadb.com/downloads/connectors/connectors-data-access/nodejs-connector" class="button primary">Download MariaDB Connector/Node.js</a></p>

MariaDB Connector/Node.js is used to connect applications developed on Node.js to\
MariaDB and MySQL databases. The library is LGPL\
licensed.

## About MariaDB Connector/Node.js

MariaDB Connector/Node.js is a native JavaScript driver.

### Obtaining the Driver

The required files can be downloaded from: [connector](https://mariadb.com/downloads/connector)

The source code is available on GitHub: [mariadb-connector-nodejs](https://github.com/MariaDB/mariadb-connector-nodejs)

MariaDB Connector/Node.js on npm, the package manager for JavaScript: [npm mariadb](https://www.npmjs.com/package/mariadb)

### Installing the Driver

The driver can be installed using npm:

```bash
npm install mariadb
```

### Choosing a Version

Driver versions are compatible with all MariaDB servers and MySQL 5.x (>= 5.5.3).\
Tested with all active MariaDB server versions with Node.js 20+ (see [CI tests](https://github.com/mariadb-corporation/mariadb-connector-nodejs/actions) on ubuntu/windows/macOS).

### Requirements

MariaDB Connector/Node.js requires Node.js 20 or above.

### License

GNU Lesser General Public License as published by the Free Software Foundation;\
either version 2.1 of the License or (at your option) any later version.

## Using the Driver

The MariaDB Connector can use different APIs on the back-end: [Promise](/docs/connectors/mariadb-connector-nodejs/connector-nodejs-promise-api.md) and [Callback API](/docs/connectors/mariadb-connector-nodejs/connector-nodejs-callback-api.md). The default API is Promise. The callback API is provided for compatibility with the mysql and mysql2 APIs.

{% @marketo/form formId="4316" %}
