This is a very generic question, I think the easiest answer would be to work out regularly, eat right, drink plenty of water and get enough sleep. But easier said than done.
Keep yourself in discipline, this would help you in maintaining your heath too.
If your mental health is good, then physical health wouldn't have much problem and it can be done by keeping yourself in a discipline for better result.
If you really want to stay healthy, You just need to eat some fresh vegetables, fruits, juices and fish, as it's my diet plan for past few years and do some regular walk and exercise to digest well and stay health.