This is a very old rhyme, dating back as far as the 15th century.
It was very popular in the 19th century when there was another verse preceding this one which went:
“The cock crows in the morning
To tell us to rise,
And he that lies late
Will never be wise.”
James Thurber, the American writer and cartoonist, wrote a funny parody of it as follows:
“Early to rise and early to bed,
makes a male healthy, wealthy and dead!”
The modern version is short in it goes like this:
“Early to Bed” Lyrics
Early to bed and early to rise
Makes a man, healthy, wealthy and wise.