Node.js
Supported projects
The following projects are recommended for implementing Node applications using the YugabyteDB YSQL and YCQL APIs.
Project | Documentation and Guides | Latest Driver Version | Supported YugabyteDB Version |
---|---|---|---|
YugabyteDB node-postgres Smart Driver | Documentation |
8.7.3-yb-1 | 2.8 and above |
PostgreSQL node-postgres Driver | Documentation |
8.7.3 | 2.6 and above |
YugabyteDB Node.js Driver for YCQL | Documentation |
Project | Documentation and Guides | Example Apps |
---|---|---|
Sequelize | Documentation Hello World |
Sequelize ORM App |
Prisma | Documentation Hello World |
Prisma ORM App |
Learn how to establish a connection to a YugabyteDB database and begin basic CRUD operations by referring to Connect an app or Use an ORM.
For reference documentation, including using projects with SSL, refer to the drivers and ORMs reference pages.
Prerequisites
To develop Node.js applications for YugabyteDB, you need the following:
-
Node.js
To download and install Node.js, refer to the Node.js documentation.
To check the version of node, use the following command:node -v
-
Create a node.js project
Create a file with the.js
extension (for exampleapp.js
), which can be run using the following command:node app.js
-
YugabyteDB cluster
- Create a free cluster on YugabyteDB Managed. Refer to Use a cloud cluster. Note that YugabyteDB Managed requires SSL.
- Alternatively, set up a standalone YugabyteDB cluster by following the steps in Install YugabyteDB.