Identifying chemical compounds in foods and assaying their bioactivities significantly contribute to promoting human health. In this work, we propose a machine learning framework to predict 101 classes of health effects of food compounds at a large scale. To tackle skewedness of class distributions commonly encountered in chemobiological computing, we adopt random undersampling boosting (RUSBoost) as the base learner. In this framework, all chemical molecules including food compounds, natural products and drugs are encoded into MACCSKeys similarity spectrums to define the fingerprint similarities of functional subgroups between molecules of interest with predefined template molecules. Five-fold 5-fold cross validation shows that RUSBoost learners encouragingly reduces model biases. Independent tests on external data show that the proposed framework trained on food compounds generalizes well to natural products (0.8406 ~ 0.9040 recall rates for antibacterial, antivirals, pesticide and anticancer effects) and drug molecules (0.789 ~ 0.9690 recall rates for antibacterial, antiviral, antineoplastic and analgesic effects). Furthermore, dozens of novel effects have been validated against recent literature, convincingly demonstrating knowledge transferability between food compounds, plant or microbial natural products and drugs. Especially, evidences show that the proposed framework helps us to repurpose drugs or find lead compounds for anticancer therapies and bacterial drug resistance. Lastly, we attempt to use the proposed framework to unravel beneficial and risky health effects of food flavor compounds, which potentially benefits recipe composing.