How to run Magento 2 console commands on a server

  1. Install a SSH client program like PuTTY (simplier) or Cygwin (more complex and powerful, I prefer it).
  • Connent to your server through the SSH protocol.
  • Set the Magento 2 root directory as the current directory with the cd commmand.
  • Run the Magento 2 console commands you need.