Pick near wind-less days. Avoid excessive cold days. Avoid adding any accessories that will create either drag or add weight. Don't pop into sports mode too often.
But I can concur with most others here, I'm typically looking at most 25 minutes with spare battery to accommodate my return back to the take off point, usually I go up, get some video fly bys and do some panoramic shots from about 3 or 4 vantage points and then return.
Also far as battery health itself, I try not to completely drain the batteries to 10% or so. But also I avoid charging the batteries right after a flight, and avoid using the batteries right after being fully charged. Ideally having an hour between discharge and charge prevents excessive wear (I'll usually charge them up a night before I plan on a trip, rather than on the road leading up to the location).
PS: I had a near windless day last week where the gust was at most 3~4mph. It definitely improved my estimated battery indication over the usual parts of the year where there was always around 10mph~15mph wind or more.