The perovskite BaTiO3 was synthesized by solid-state reaction, and the formation of a single-phase, crystallizing in a cubic perovskite structure was confirmed by X-ray diffraction. Optical characterization revealed a direct band gap of 3.27 eV, with an absorption in the UV region without phonon assistance. The Mott–Schottky analysis confirmed n-type semiconductor behavior with a flat-band potential of -0.466 V vs. NHE, and allowed the conduction band (CB) position (− 3.82 eV vs. Vacuum), demonstrating favorable energy alignment with the Rhodamine B (Rh B) excited state for electron injection. The photoelectrochemical properties of BaTiO3 indicate an enhancement in solar cell efficiency due to the LUMO level of Rh B, more cathodic than the conduction band of BaTiO3, which promotes a thermodynamically favorable injection of electrons (ΔGinject ≈ 0.6 eV). Consequently, Rh B is identified as an attractive photosensitizer for dye-sensitized solar cells (DSSCs). Its adsorption, photophysical properties, and photovoltaic potential in aqueous solution were systematically investigated. To support the experimental findings, and gain molecular-level insight, time-dependent density functional theory (TD-DFT) calculations were performed at the B3LYP/6–311 + + G (d, p) level. The results revealed visible-light absorption (λmax = 550 nm), with “HOMO–LUMO” gap of 2.8 eV, and an energetically favorable frontier orbital alignment for efficient charge transfer. The molecular dynamics (MD) simulations confirmed spontaneous and stable adsorption of Rh B on the BaTiO3 (001) surface, yielding a calculated adsorption energy of − 44.08 kcal mol⁻1. These combined results demonstrate that the “Rh B/BaTiO3” system exhibits favorable electronic alignment, strong interfacial interaction, and efficient photoinduced charge transfer. This work provides a comprehensive mechanistic understanding of dye sensitization on the perovskite BaTiO3 and highlights its potential for applications in photocatalysis and dye-sensitized solar energy conversion.