Santa Maria in Via is a basilica church in Rome. The church or a chapel existed in the 9th century, but was rebuilt following reports of a miracle. In 1165, it is recorded as Santa Maria in Via, whose appellative means "on the Way", with a reference to the close by Via Flaminia. On the site there was the house of Cardinal Pietro Capocci, with a well in the stables. On the night of 26 September 1256, the well overflowed. A picture of Our Lady was floating on the waters, which disappeared as soon as the picture was taken. Pope Alexander IVdeclared it a miracle, and ordered the construction of a chapel on its place; in the chapel there is still the well of the miracle.