The history of the Indian settlement of Rancagua as a city begins in 1743 when the last leader of the Mapuche tribe Tomás Guaglén left his lands. In the same year, the city council granted a small plot not far from the modern Plaza de los Héroes to the Mercedarians for the construction of the monastery. Construction had lasted four years until 1754. The new Mercedarian temple was named San Ramón Nonato in honor of the head of the monastic order, the canonized cardinal. A few years later, its name was changed to the Church of La Merced.
The church building had a rectangular shape and was made of adobe, which is typical for the architecture of the 18-19th century. The only tower had an octagonal facade with a curved spire. And the roof was covered with clay tiles. The interior of the temple did not have any decorative elements, only smooth white walls. All the decorations were added to the interior only at the end of the 19th century.
The most important dates in the history of the Catholic Church are considered to be the first days of October 1814, when General Bernardo O'Higgins was besieged by Spanish Colonel Mariano Osorio and took refuge in the church tower. It was no use waiting for reinforcements: no one came to the aid of the patriot army. His soldiers had fought bravely for two days but were unable to furnish resistance. Some of them eventually managed to escape to the city of Mendoza. This was the defeat of the patriotic movement of Chile and the end of the Chilean Patria Vieja (Old Homeland).
Throughout its long history, the church building has undergone many changes but the most destructive for it was the earthquake of 2010. The temple had to be closed due to numerous serious damages. It had been empty for four years until the restoration work began in 2014. The grand opening of the church and the exhibition hall dedicated to the Mercedarians and the Battle of Rancagua took place in 2016.