What is the origin of the phrase goodbye?

The expression was originally "God be with Ye (or you)", as a sort of blessing or good luck phrase to someone leaving your presence and was later shortened to 'good bye'.