Express 4.x app using Passport for authentication with username and password stored in MySQL.

Usage no npm install needed!

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



Express using passport.js to login, signup, logout users against credentials in MySQL db

This example demonstrates how to use Express 4.x and Passport to authenticate users using a username and password with form-based authentication connected to a MySQL database.


To install this example on your computer, clone the repository and install dependencies.

$ git clone
$ cd express-passport-mysql
$ npm install

Start the server.

$ npm start

Open a web browser and navigate to http://localhost:3000/