Aging triggers intricate physiological changes, particularly in whole-body fat-free mass (FFM) and handgrip strength, affecting overall health and independence. Despite existing research, the broader significance of how muscle health is affected by the intricate interplay of lifestyle factors simultaneously during aging needs more exploration. This study aims to examine how nutrition, physical activity, and sleep impact on FFM and handgrip strength in middle-aged men and women, facilitating future personalized recommendations for preserving muscle health. The cross-sectional analysis of the UK Biobank involved 45,984 individuals (54 % women) aged 40–70 years with a complete dataset. Multiple linear regression explored determinants of FFM and handgrip strength, considering traditional, socio-demographics, medication use and smoking as covariates, with sex and age (younger and older than 55 years) stratifications. In older men and women, higher physical activity beneficially affect both FFM (respectively Β = 3.36 × 10−3, p-value = 1.66 × 10−3; Β = 2.52 × 10−3, p-value = 3.57 × 10−4) and handgrip strength (Β = 6.05 × 10−3, p-value = 7.99 × 10−5, Β = 8.98 × 10−3, p-value = 2.95 × 10−15). Similar results were found in fiber intake for FFM in older men and women (respectively B = 3.00 × 10−2, p-value = 2.76 × 10−5; B = 2.68 × 10−2, p-value = 1.78 × 10−9) and handgrip strength (Β = 3.27 × 10−2, p-value = 1.40 × 10−3; Β = 3.12 × 10−2, p-value = 1.34 × 10−5). Other lifestyle factors influence FFM and handgrip strength differently. Key determinants influencing handgrip strength included higher protein intake, lower water intake, higher alcohol intake, and extended sleep duration whereas mainly higher water intake is associated with higher FFM. In both men and women, the main factors associated with FFM and handgrip strength are physical activity and fiber intake, which may underlie a connection between gut and muscle health. Given the observed complexity of muscle health in the age and sex strata, further longitudinal research is needed to provide personalized lifestyle recommendations.