Grace commonly refers to a smooth and pleasing way of moving, or a polite and thoughtful way of behaving. But when someone says they were late to the airport and only made it onto their plane by the grace of God, they're talking about grace in the context of God's favor.
When used in the plural, the social graces are the skills needed for being polite. If you are "in someone's good graces," they regard you with favor. In Middle English, the word grace originally meant "God's favor or help," a sense that we still use today. The related word gracious originally meant "filled with God's favor or help." Grace was borrowed from Old French, from Latin gratia "pleasing quality, favor, thanks," from gratus "pleasing."