New bi-anchoring donor–π–acceptor metal-free organic dyes based on diphenylamine as donor, and barbituric acid and thiobarbituric acid as the acceptor/anchor were synthesized, characterized and used in dye-sensitized solar cells applications. Among the fabricated dye sensitized solar cells, device based on the diphenylamine as donor, and barbituric acid as the acceptor exhibits a high power conversion efficiency of 1.53% with a short circuit current density of 3.71mAcm−2, an open-circuit photo voltage of 0.55V and a fill factor of 0.75% under AM 1.5 illumination (85mWcm−2) compared to the other fabricated devices. The structure of synthesized dyes was optimized and their electronic structures studied.