I'm studying nutrition at a tertiary level for pretty much this exact reason and what it has taught me from speaking to dietitians who teach my course and from doing the course is:
a. Advice for the average person with a typical western diet boils down to "would it kill you to eat a damn vegetable?"
b. There's a lot of organic chemistry that despite me being 3 years into a 4 year degree hasn't paid off (I am doing the degree that feeds into a masters of dietetics, so I'm sure that's where it was going to pay off. Alas, I'm not going to do that masters any time soon because my government engineering job 8 years in pays more than and end of career dietitian despite the higher level of education, and the masters would require me to work 9-5 for 6 months for free)
But most importantly, and most relevantly for the lesswrong sort of person, is that it is basically impossible to study diets in anything resembling double blind randomised placebo controlled. Diets are strongly linked to culture and personality and strongly influenced by those around you and virtually impossible to double blind. Like, imagine you wanted to study whether eating red meat is good for your health. Imagine getting 10,000 people and randomising them into three groups (high red meat, moderate red meat, no red meat). Would a steer farmer from Texas really stop eating red meat just because he was randomised into the no group? Would I, a vegan for 5 years, start eating 4 serves of red meat because I was randomised into the high group? (no, but I wouldn't sign up for the study for this reason, which is a confounder because people like me then wouldn't sign up). And if the Texan did stop eating red meat, would he keep it up for 20 years? Would someone randomised into the high group who got diagnosed with heart disease and was told by their doctor to cut down on red meat ignore the advice because of the study?
It's that problem but writ large that makes decent dietary research hard to do. You'll notice a lot of studies are done over 1-3 months, because that's a reasonable amount of time to be able to provide three pre-packaged meals to your participants that you can control exactly (though those participants are probably going to eat other things: who goes to a birthday party without eating cake, for example?).
So then we have to do animal studies, and our ancestral diet is very different from say a mouse or even a chimp, and is maybe not even what is best for us.
Also, something that isn't really emphasised in this sort of discussion is the cultural value of food. Sitting and sharing meals with people is good for our mental wellbeing.
I think some people also stick on "are eggs good or bad for you? is red meat healthy? are tomatoes good?" when this is kinda missing the point. No one thing should be such a big part of your diet that this information is gamebreaking. And I think everyone knows that vegetables are healthy and hamburgers aren't.
So, where does that leave us?
Fortunately, pretty much every country in the world has a team of dietitians who come together to make a guide for how to eat healthfully. I'm Australian so the Australian guide to healthy eating ( https://www.eatforhealth.gov.au/guidelines/australian-guide-healthy-eating ) and the associated material on the website is what I'm most familiar with. It boils down to eating a lot of vegetables (50% of your plate!), a moderate amount of grains, a small amount of lean protein, and eating fruit and calcium-rich foods. But the website has a lot of information on it in a very accessible format and I'd recommend it as a good starting point.