Basic Server Hardening Checklist for a Fresh Linux VPS

admin 👑

admin

Administrator
Staff member
May 19, 2025
101
3
18
server-hardening-banner.png
🛡️ A fresh Linux VPS is wide open by default. Here's a basic hardening checklist worth running through before putting anything important on it.
  1. 👤 Create a non-root user with sudo privileges, and disable direct root login over SSH.
  2. 🔑 Switch to SSH key authentication and disable password login entirely.
  3. 🚪 Change the default SSH port (optional, but cuts down on automated scan noise significantly).
  4. 🧱 Set up a firewall (ufw/firewalld) and only open the ports you actually need.
  5. 🔄 Enable automatic security updates for the OS at minimum.
  6. 🚨 Install fail2ban to automatically block IPs after repeated failed login attempts.
  7. 📋 Disable unused services running by default that you don't need.
💬 What's the first thing you do on a brand-new server before anything else?
 
Last edited: