res.setHeader('Content-Type', 'text/html;charset=utf-8'); Install npm install zgw-tools Import const ztest=require('zgw-tools') Formatting time //invoking dateFormat Format the time const dtstr=dt.dateFormat(new Date()) //result 2022-08-01 16:16:00 console.log(dtstr) Open source protocol ISC