The electronic configuration of O2 molecule on the basic of MOT is : (σ1s)2(σ∗1s)2(σ2s)2(σ∗2s)2(σ2pz)2(π2px)2(π2py)2(π∗2px)1(π∗2py)1
Thus, due to the presence of an unpaired electron each in (π∗2py)1 and (π∗2px)1,O2 molecule is paramagnetic.