When thou liest down, thou shalt not be afraid: yea, thou shalt lie down, and thy sleep shall be sweet.@Proverbs 3:24

Harriet Parr, in Wreck of the Golden Mary, 1856.

[The story] was the Christmas number of Charles Dickens’ Household Words, 1856. The way in which the hymn is introduced into the story has often been told, and is worth repeating. The story sets forth how the ship Golden Mary, on her voyage to California, struck on an iceberg, and the passengers, taking to the boats, suffered privations for several days. To beguile the time they repeated stories. One of them, Dick Tarrant, a wild youth, relates some of his experiences, in which he says:—

What can it be that brings all these old things over to my mind? There’s a child’s hymn I and Tom used to say at my mother’s knee, when we were little ones, keeps running through my thoughts. It’s the stars, may be; there was a little window by my bed that I used to watch them at, at a window in my room at home in Cheshire; and if I were ever afraid, as boys will be after reading a good ghost-story, I would keep on saying it till I fell asleep.

That was a good mother of yours, Dick; could you say that hymn now, do you think? Some of us might like to hear it.”

It is as clear in my mind at this minute as if my mother was here listening to me, said Dick. And he repeated

Hear my prayer, O Heavenly Father,
Ere we lay us down to sleep,
[sic] &c

Julian, p. 882

Springhill William F. Hurndall, 1878 (🔊 pdf nwc).

Hear my prayer, O heavenly Father,
Ere I lay me down to sleep;
Bid Thine angels, pure and holy,
Round my bed their vigil keep.

Great my sins are, but Thy mercy
Far outweighs them every one;
Down before the cross I cast them,
Trusting in Thy help alone.

Keep me, through this night of peril,
Underneath its boundless shade;
Take me to Thy rest, I pray Thee,
When my pilgrimage is made.

None shall measure out Thy patience,
By the span of human thought;
None shall bound the tender mercies
Which Thy holy Son has wrought.

Pardon all my past transgressions,
Give me strength for days to come,
Guide and guard me with Thy blessing,
Till Thine angels bid me home.