start here: The Basics of Remote Access Troubleshooting / use a “manual” port forwarding
Additionally:
- always use a wired network connection between your server and the router
- disable power saving in the properties of the network adapter in your server
- don’t allow the network adapter to lower the link-speed when idle
- make sure that “Support Away Mode when preventing system sleep” is enabled under Settings - Server - General - Show Advanced
- don’t force your server into hibernation mode