WWW FAQs: How do I record an MP3 file?

2006-11-06: In the article how do I embed sound and music in a page, I sort out how to embed MP3-format music in your web pages. But how do you record an MP3 file to begin with?

Requirements to Record MP3 Files

1. For speech and most musical performances, you'll need a microphone! For singers and spoken word artists, I strongly recommend the Shure SM58. But lesser microphones can sometimes produce acceptable results, especially for low-fi "podcasting" (audio blogging). Still, the better the input, the better the output. Musicians will usually have electric or acoustic-electric guitars. Those who play other instruments will need to mic them appropriately. For group performances, or electric guitar plus vocals, you may need to purchase an inexpensive USB mixer so that everyone can plug in their equipment.

2. A computer with a suitable audio input device. For better quality, or if you just don't have an audio card in your desktop PC, you can use a USB audio input device. These are inexpensive and they place the audio input circuitry further away from your noisy CPU. I've had excellent results with a very inexpensive gadget called the Griffin iMic (marketed mostly for Macintoshes, but it works fine with my Windows laptop). Again, USB mixers are also available, and for large-group performances they may be essential so that everyone can be separately mic'd. Musicians' Friend offers a good selection of USB mixers.

3. Audacity, an excellent piece of free, open-source audio recording and editing software for Windows, MacOS X and Linux. You could use something else, but it would only cost you money. Serious high-end music producers will probably want something like CakeWalk Pro, but for most people Audacity is tough to beat at the price.

4. The LAME MP3 Encoder, a necessary add-on to allow Audacity to export MP3 files. For legal reasons, Audacity does not support MP3 "out of the box." But it's easy to install LAME.

This article is about recording new music or speech performances. To convert existing files, see the article how do I convert my music to MP3 format?

Converting Your Songs With Audacity

Audacity is a simple, friendly audio recording and editing program. Although it is mainly intended as a musician's recording tool, it's also a fine choice for our purposes. You can easily obtain Audacity for Windows by visiting the Audacity for Windows download page and carefully following the instructions there to download and install the software on your computer.

There's one big catch with Audacity: for legal reasons, the filter that converts other formats to MP3 is not included "in the box." Are we stuck? Of course not! We just have to visit a separate website to pick up the MP3 filter, lame_enc.dll.

Audacity's how do I download and install the LAME MP3 encoder? page explains in detail how to take care of this step. Read it and follow the directions carefully.

Do you have Audacity and its MP3 encoder installed at this point? Great! You're ready to move on to "recording" and converting your audio files. Just follow these steps to convert your first song!

1. If you have not already followed the steps above to set up your computer to record its own output, do so now.

2. Launch the Audacity software.

3. Click on the round red "Record" button. Audacity will begin recording. Time for you to start performing!

4. When you have finished your performance, go back to the Audacity window. Audacity should still be recording. Click the square yellow "stop" button.

5. Right now there's some "dead air" at the beginning and end of your track. You can clean that up now if you wish. Use the scrollbar in Audacity to locate the silent sections at the beginning and end of the song. Select those areas with the mouse, then pick "cut" from the "Edit" menu to remove them. If you make a mistake, just select "Undo" from the "Edit" menu. You can also clip out unwanted "goofs" from the middle of the recording, or silence them and rerecord those portions in a second track— Audacity offers many possibilities beyond the scope of this article.

6. Click "Play" to listen to what was recorded. If the sound is distorted, your recording level was too high. Adjust the slider to the right of the microphone icon in the Audacity window. Then select "Undo" in Audacity to undo the recording, and start a new recording. (If you don't undo the old recording, you'll record a second track of audio, like a second instrument's performance in a song.)

7. When you are satisfied with the sound, pull down the "File" menu and select "Export as MP3..."

8. If you have not already done so, you will be prompted to locate the lame_enc.dll file. If you have not yet downloaded the MP3 filter for Audacity, visit the how do I download and install the LAME MP3 encoder? page and follow its instructions carefully.

9. In the "Save MP3 File As" box, enter a name for your MP3 file. You don't have to type the .mp3 extension at the end.

10. The "Edit the ID3 tags for the MP3 file" window appears. ID3 tags contain information such as the title, album title, and artist's name. Enter as much information about the song as you wish. Skipping this step is a very bad idea because no information about your song will show up in the music player.

I recommend you select the "ID3v1" radio button, because more players understand that type of ID3 tag.

When you're done, click "OK."

"Why does my MP3 file sound like a chipmunk in Flash player?"

The instructions in this article will work great if you don't try to change the MP3 bitrate from the default of 128kbps. If you do lower the bitrate, Audacity will create MP3 files that Flash player doesn't handle very well. That's because Audacity allows LAME to encode them with a "sample rate" that Flash Player doesn't support. If you really want to use low-bitrate MP3s (hopefully for voice, not high-quality music), you can export your file as a WAV file instead of an MP3 and run LAME manually at the command line. For more information and complete details on the solution, see why do my MP3 files sound bad in Flash Player?

When you click "OK," Audacity will export your song to the MP3 format and save it to the filename you specified. This can take a little time if the recording is a long one.

When you're finished, you have a .mp3 file that is compatible with the XSPF Flash Music Player and other MP3-based software. For more information on what you can do with MP3 files on your website, see the article how do I embed sound and music in a page?

Be sure to also save your original source material with the "Save" option on the File menu. This produces an Audacity project file that can be reopened later. Because quality declines with every save, MP3 files should not be re-opened, re-edited and re-saved if at all possible. So it's essential to keep your original "raw" full-quality project files around as well.

Share |

Legal Note: yes, you may use sample HTML, Javascript, PHP and other code presented above in your own projects. You may not reproduce large portions of the text of the article without our express permission.

Got a LiveJournal account? Keep up with the latest articles in this FAQ by adding our syndicated feed to your friends list!


Follow us on Twitter | Contact Us

Copyright 1994-2014 Boutell.Com, Inc. All Rights Reserved.