1. Input Validation: Always validate user input to protect your application from code injection attacks. Never trust user’s input blindly.
1. Use TLS: Make sure the data is always transferred over a secure connection.
1. Use Helmet.js: Helmet.js is a collection of middleware functions that help secure HTTP headers returned by your Express apps.
1. Keep Node.js and Packages Updated: Always make sure that your node.js and all its packages are constantly updated. It will help in preventing security breach.
1. Using strong session cookies: Application cookies should be HttpOnly to make it impossible to scan it using JavaScript, and should be as secure as possible.
1. Implement Error Handling: Implement to catch unhandled exceptions, promise rejections and use process.on to catch those exceptions at the process level.
1. Secure Dependencies: Make sure to add reliable modules and ensure you update them, monitoring all of modules using safety tools like nsp or Snyk.io.
1. Use Strict Mode: Put “use strict”; at the top of your node.js files to catch common mistakes.
1. Code Auditing: Implement a code review and auditing system. This way you will be able to identify any vulnerability in your code.
1. Restrict Processes: Always run Node.js as a non-root user in your operating system. This can limit the damage that an attacker can do if they leverage a vulnerability in your application.
1. Preventing Cross-Site Scripting attacks (XSS): Make sure to sanitize and escape HTML from content created by users.
1. Using Appropriate Content Security Policy: It prevents a wide range of attacks including cross-site scripting and other cross-site injection.
1. Implement Rate Limiting: Implement application-level rate limiting which provides a token bucket-style rate limit with customizable keys.
1. Logging and Monitoring: Regularly check logs and monitor them to find and fix the stipulations causing a lot of errors.
1. Use a WAF: You could consider using web application firewalls like Cloudflare, AWS WAF etc for additional security.
Remember, no application can be 100% secure, but these practices will go a long way in safeguarding your Node.js application.