To expound upon g-bones' point of electronegativity, oxygen is more stable with a negative charge due to electronegativity, so it then follows that the pka of phenol is lower than aniline, since pka is representative of the stability of the anion resulting in from deprotonation. As a side note, phenol is not a strong acid..