There are various bits of software out there for recording live Internet audio streams but many people often overlook the simple free solutions already available.
Audacity is a piece of free recording software that is cross-platform and can easily be set to record from your computer internal audio. Once recorded it will offer you the choice of saving as an mp3, AAC, ogg or various uncompressed formats.
Set To Record From The Built In Input
Just make sure that Audacity is set to record from the built-in input (Audacity -preferences-devices-recording: change to built-in input).

Audacity will now record anything playing on your computer so fire up that online audio stream via a web browser or your chosen piece of audio stream player (media player, iTunes,vlc etc), adjust your system volume level and the Audacity recording level and you’re ready to record.
Windows uses may have to make some extra adjustments.
Audacity Now Has A Timer
In fact the latest version (1.3.13) adds a timer recording capability (under the Transport menu or Shift+T from your keyboard once audacity is running).

Of course when using the timer facility will inevitably require that you’ll have to pre-start the playback of your audio stream in advance or delve into the world of software scheduling on windows, automator on OS X or gui front ends for cron jobs in linux such as gnome-schedule (perhaps I can look at these additional options another time).
Bring Your Own Radio
Recording internal audio doesn’t mean that you have to record Internet streams. You could just as easily connect an ordinary FM/AM radio, Digital radio, standalone Internet radio or satellite radio to your system input via the proper cable and set these to come on at a chosen time.
Download a PDF of this article here