Perhaps this seemingly fundamental question is not quite as simple as it seems...
Linux is the first choice for an autonomous running application, especially when it comes to stability and (network) security in critical structures and can be flexibly customized to specific requirements.
For an existing system, Windows often holds the edge, since many components, software and applications usually run on Windows and integration - not least due to usability and support - is easier and can be maintained more efficiently.
Ultimately, not only personal preferences, but also the functions and features will decide which operating system is best for your new application.