Margaret was born in Hungarian exile to Edward the Exile (grandson of Æthelred the Unready) and the Hungarian princess Agatha. After the Norman Conquest of 1066 her family fled north to the Scottish court, where she married King Malcolm III in 1070. She bore him eight children — three of whom (Edgar, Alexander I, and David I) would become kings of Scotland, and one daughter (Edith/Matilda) would marry Henry I of England.
She brought Continental and Roman reform to a Scottish Church that had drifted from Latin usage during the centuries of Hiberno-Scottish isolation. She summoned synods that aligned Scottish practice with Rome on Easter dating, Lenten observance, Sunday rest, and reception of communion, and she rebuilt the abbey of Iona and founded the Benedictine abbey of Dunfermline, which became the royal burial church of Scotland.
Her personal life was an austere combination of royal hospitality and severe penance — washing the feet of the poor every morning, feeding orphans before she ate, and praying through long vigils. She died on November 16, 1093, three days after learning that Malcolm and their eldest son had been killed in battle at Alnwick. She was canonized by Innocent IV in 1250.

