Mac McLernon at Mulier Fortis has some information on the Sign of the Cross.
The sign itself originated in the sixth century, at least in the form used now, but goes back in some form to at least the second century. No where is it mentioned in scripture, but is a cultural tradition. As mentioned at Mulier Fortis the Blessed Virgin Mary made the Sign of the Cross when she appeared to St. Bernadette. In the Eastern Churches the sign is done from right-to-left. In the Latin Churches from left-to-right. It should always be done with the greatest reverence.
Often making the sign includes the use of Holy Water, as when entering or leaving Church. Holy water is, of course, a sacramental, and its use in this manner is intended to be a reminder of the Sacrament of Baptism.
We also begin and end our prayers with the Sign of the Cross. It is proper to use it as a personal devotion when receiving Communion. It is also properly used when saying the doxology during Liturgy of the Hours, which are also begun and ended with the Sign of the Cross (except for the Invitatory, which starts with a cross made on the forehead, which is the original form of the sign.)