PostgreSQL Core Driver for NodeJS.

Usage no npm install needed!

<script type="module">
  import pgCore from '';



PostgreSQL Core Driver for NodeJS.

Build Status Coverage Status

Initially based on node-postgres and its core packages, this core library for PostgreSQL is independent of the original work. Its goal is improved and simplified support with timely updates and bug fixes.


$ npm install pg-core


var pg = require('pg-core');

The library exposes the same object as the original pg, with the addition of:

and with the exception of:

  • pg.native - native libpq bindings have been fully removed.

Apart from these differences, the original node-postgres is a reliable source of documentation that entirely covers functionality of this library as well.


For details on running tests on your local machine see testing pg-core.


The original snapshots were taken on November 11, 2015, and included:

All code changes later committed for original packages are merged into this library. For details see the merge history.

What's Changed

The following has been changed from the original node-postgres library:

  • Completely removed - pg.native, only javascript implementation is supported;
  • The library has being refactored for ES6 compliance
  • All dependencies are kept up-to-date, no use of obsolete packages;
  • Supported environments: NodeJS 0.10 - 5.x, PostgreSQL 9.x, Win/Linux/OS-X
  • New tests are being written in place of the old ones. YOUR HELP IS WELCOME!


The original license note can be found here.