If you like to fall asleep with music playing but don’t want to leave your iPhone playing music all night long, you can turn on its sleep timer.
Here’s how:
On the Home screen, tap the Clock icon.
In the lower-right corner, tap the Timer icon.
Set the number of hours and minutes you want music to play, and then tap the When Timer Ends button.
Tap the last item in the list, Sleep iPod.
If you don’t see the Sleep iPod item, don’t be alarmed (semi-clever wordplay intended). You’re simply looking at the middle (or the beginning) of the list of available alert sounds. To scroll to the bottom of the list and find the elusive Sleep iPod item, flick upward on the list a few times.
In the upper-right corner, tap the Set button.
Tap the big, green Start button.
That’s it! If you have music playing already, you’re finished. If not, press the Home button, tap the Music button, and select the music you want to listen to as you fall asleep. When the specified time period elapses, the music stops playing and your iPhone goes to sleep. By then, you should be in slumberland as well.