Building work on the church was started in 1380, and further building and rebuilding has taken place up to the present day. It is the longest church in Scotland, at 206 feet (62.8 metres) from east to west, and is in the early Gothic style.
The cruciform church is located in a large open churchyard, at some distance from the town centre. The church is built on a scale becoming of a cathedral. It is of a uniform and consistent design, that suggests a clear adherence to the original plans. Having been desecrated during the sixteenth century, the nave of the church and the tower were repaired for use by the congregation, this part being subject to various restorations in subsequent centuries. A comprehensive renovation of the whole church was carried out in the 1970s.
The choir is aisled and is made up of four bays, intersected by buttresses with a mixture of gabled and pinnacled terminals. The windows between have simple curvilinear tracery dividing two main lights. The cornice below the eaves has foliate carving. The clerestory is unbuttressed and has double-lighted windows beneath two mouchettes. The window at the east end of the choir was built in 1877, and consists of four lights with contemporary tracery. One of the finials shows an angel playing the bagpipe. On the north side of the choir there is a medieval sacristy, which is now an ecumenical chapel and mausoleum of the Maitland family dedicated to the Three Kings.
The transepts are aisleless, with windows at the gables and to the west, the gable windows are triple lighted with mouchettes above. The north transept contains modern toilets and stairs to the north gallery. The south transept contains a memorial to George Seton and a stained glass window by Edward Burne-Jones donated by the Victoria and Albert Museum as part of the restoration. to the east of the north transept lies the Lauderdale Aisle, a small Scottish Episcopal chapel that commemorates John Maitland, 1st Lord Maitland of Thirlestane and others of the Maitland family. There is a stair turret in the east angle of the north transept which gives access to the tower. The tower is cubic in form and has triple lancet windows on each elevation. There are single figure niches on either side of the openings. The wall heads terminate in a decorative cornice with gargoyles. The corbelling at this level suggests that there were plans to erect a crown spire similar to that of St. Giles Cathedral in Edinburgh and St. Michael's Parish Church, Linlithgow. It is not known whether or not this decorative structure was ever built.
The nave is similar to the choir, in that it has four bays on the north and south aspects, buttressed in between. The windows, however, are similar to those on the transept gables. The side aisles were raised by some 10 feet in 1811 and were finished with castellation and pinnacles. The clerestory windows are similar to those of the aisles and the wall heads finished with cornicing. The position of the pre-1811 vaults are still visible on the sides of the nave.
The western front of the building has a large window divided into six main lights in groups of three divided by a 'Y' shaped central mullion. These are each surmounted by double mouchettes and vesica piscis windows. The capital is formed of double "dagger" and single quatrefoil windows. Below is the main door, with round headed arch composed of several filleted shafts, the door is divided into two by a trumeau shaft topped with two semi-circular arches; the capital here bears a representation of the Arma Christi.
The interior of the church is notable for the extensive sexpartite vaulting. The pulpit and font were both designed by Glaswegian sculptor, William Birnie Rhind in 1891. In the north choir aisle there is an ancient sculpture of Haddington Burgh arms, discovered in the north transept, during the 1970s restoration. The east wall of the south transept houses a memorial to William Seton, Provost of Haddington, erected in 1682. In the late 1980s a new pipe organ was commissioned, and installed in 1990 on a gallery within the north transept. The tower of St Mary's had been silent since 1548, when the English army removed the three bells extant. In 1999 the church acquired a set of eight bells, cast to celebrate the coronation of George V in 1911, and originally hung as a chime in Dunecht House. These were installed between March and May 1999 and were dedicated by The Very Rev Dr John B. Cairns, the Moderator of the General Assembly of the Church of Scotland, on the 6th of June.
Haddington was the fourth largest town in Scotland in the High Middle Ages, and the first chartered Royal Burgh. There is record of the church in Haddington in a charter of David I of Scotland dated 1139, giving the monks of St Andrews Cathedral Priory the benefits of its revenues. The king granted unam mansuram in Haddington, as well as to the monks of Haddington a full toft "in burgo meo de Hadintun, free of all custom and service". This parish church was probably built upon the site of the choir of the present edifice.
In the late 12th century the great Abbey of Haddington was founded by Ada de Warenne, Countess of Northumbria and Huntingdon, for a community of Cistercian Nuns. In addition to the Cistercians and the Franciscans, there was a representative house of the Dominican Order, a Hospitium and a Lazar house. This was represented by a hamlet within the parish of Haddington, now part of a housing estate on the outskirts of the town, called St Lawrence, a corruption of St Lazarus.
In recognition of Haddington's strategic importance in the Lothians, it was burnt twice in the 13th century by the English, once by the forces of John of England in 1216, and in 1246 by John's son Henry III of England. In early 1356, Edward III of England, following in his great-grandfather's footsteps, invaded Scotland, in an episode that would become known as the Burnt Candlemas. Edward had come north to recapture Berwick upon Tweed, taken by the Scots in 1355, this having been accomplished he overwintered at Roxburgh. There, Edward Baliol, the pretender to the Scots throne, had resigned his interest in the Scots throne to Edward. By February, 1356, Edward had crossed the Lammermuir Hills, and in revenge for Berwick, spent ten days at Haddington, where he sacked the town, and destroyed most of the buildings there, including the Franciscan Lamp of Lothian. His army ravaged the whole of Lothian, burning Edinburgh and the Shrine of the Virgin at Whitekirk.
John Knox is believed to have been born in Giffordgate, on the opposite bank of the River Tyne from St Mary's around 1514. He trained as a priest in St Mary's but never held the parish. Instead, he became a notary and then a tutor to landowning families near Haddington. These lairds supported the Reformer, George Wishart and Knox became a guide to Wishart as he travelled in the Lothians. In January 1547, Wishart preached at two services in St Mary's with Knox standing guard, below the pulpit bearing a two handed sword. There is no record of Knox having preached in St Mary's, but, as he was ordained priest there and the inventory of his estate showed that he had a pension from the Kirk in Haddington, it seems likely.
By 1380, the townsfolk of Haddington had recovered enough to start building a new foundation. The kirk of Saint Mary took nearly a century to build, being consecrated around 1410 by Henry Wardlaw, Bishop of Saint Andrews; the structure was completed in 1462. However, in a document from this date the prior of Saint Andrew's promised a grant of £100 for the embellishment of the choir.
The Reverend Alison McDonald was appointed as minister of the church in July 2019, following the death in March 2018 of the Reverend Jennifer Macrae.