The angle of contact is influenced by the surface energy of both the liquid and the solid surface. Lower surface energy of the liquid or higher surface energy of the solid surface leads to smaller contact angles, indicating better wetting and adhesion.