Although you can host a server directly from inside the game, HKMP also offers a standalone server for cases where you want to keep a server up while not running the game. This article goes over everything you need to know about HKMP's standalone server.
You should have first port forwarded or set up a P2P VPN app like Hamachi or ZeroTier if you're hosting on the internet, and you should already be aware of what IPs you and others will be using to join the server. If you're clueless about this stuff, you need to look into the "Host a server" section.
If you’re on macOS or Linux, you need to also install Mono before proceeding.
cd [server's folder path]
and press EnterHKMPServer.exe {port number}
and press Entermono HKMPServer.exe {port number}
and press EnterWhile your server is running, you can enter commands into the HKMPServer terminal window. You can use the same commands available in the in-game chat.
If you’re intending to use HKMP addons, they can be installed into the server by inserting the dll file of the addon into the same folder as your standalone server exe. You can get the dll file from your own mods folder (click ‘Open Mods’ in a mod installer). Learn more about HKMP Addons.