Who told Mary she was having a baby?

The angel Gabriel was the one who told Mary she was going to have a baby. She was about to be married to Joseph when the angel visited her.