Viral infection requires stable binding of viral fusion proteins to host membranes, which contain hundreds of lipid species. How viruses sense lipid compositions to target suitable host cells is poorly understood. Using multi-scale molecular simulations, we computed 66 membrane binding free energies of fusion proteins from classes I–III with various lipid compositions and identified distinct mechanisms of lipid recognition. We find that membrane binding of class II and III proteins, but not of class I proteins, is greatly modulated by the content of polyunsaturated lipids, cholesterol, anionic lipids, or gangliosides. Fusion proteins bind specific membranes by chemically recognizing distinct head group moieties and by sensing packing defects. The results show that lipid recognition of class II and III fusion proteins is a key feature to selectively bind to mammalian plasma membranes or to membranes of the endosomal compartments.