The predicted structure has been calculated for a protein-based biosensor for inorganic phosphate (Pi), previously developed by some of us (Okoh et al., Biochemistry, 2006, 45, 14764). This is the phosphate binding protein from Escherichia coli labelled with two rhodamine fluorophores. Classical molecular dynamics and hybrid Car-Parrinello/molecular mechanics simulations allow us to provide molecular models of the biosensor both in the presence and in the absence of Pi. In the latter case, the rhodamine fluorophores maintain a stacked conformation in a 'face A to face B' orientation, which is different from the 'face A to face A' stacked orientation of free fluorophores in aqueous solution (Ilich et al., Spectrochim. Acta, Part A, 1996, 52, 1323). A protein conformation change upon binding Pi prevents significant stacking of the two rhodamines. In both states, the rhodamine fluorophores form hydrophobic contact with LEU291, without establishing significant hydrogen bonds with the protein. The accuracy of the models is established by a comparison between calculated and experimental absorption and circular dichroism spectra.