A simple tool to find an open port or domain socket on the current machine
Latest commit ffe3f01 Jan 17, 2017 @eriktrom eriktrom 1.0.12


node-portfinder Build Status


  $ [sudo] npm install portfinder


The portfinder module has a simple interface:

  var portfinder = require('portfinder');

  portfinder.getPort(function (err, port) {
    // `port` is guaranteed to be a free port
    // in this scope.

By default portfinder will start searching from 8000. To change this simply set portfinder.basePort.

Run Tests

  $ npm test

Author: Charlie Robbins

Maintainer: Erik Trom

License: MIT/X11