Before you are able to insert AdSense code into your videos on YouTube, you must apply to the YouTube partnership program. Not just anyone is approved for this program. At the time of publication YouTube approves only original videos that reach a wide audience. This means, for example, that if you have videos using a popular song in it, or if you only have a couple videos uploaded without many viewers, chances are you will not be able to put AdSense on your videos. Make sure your videos meet YouTube's guidelines for inclusion in the program before applying.
Upload original videos to YouTube. Every part of the videos must be original content that you have full worldwide copyright ownership. Any videos containing music, lyrics, images, text, owned by someone else will make it unlikely you will be approved. This includes cover songs performed by you of another performer's commercial work.
Make sure that all of your videos, and your conduct on YouTube complies with the Terms of Service for your account, and YouTube's Community Guidelines.
Upload new videos to YouTube regularly.
Make sure your videos have popular appeal, and are viewed by thousands of viewers before applying.
Go to the YouTube Partnership Program page and apply, then wait for YouTube to review your account and your videos.
Use the instructions sent to you from YouTube to create an Adsense account, which will be linked to your YouTube account. If you already have an account, continue with the following steps.
Sign into Google Adsense using your AdSense account. Click "My Account," and select "Account Access."
Open a new browser window. Sign into YouTube using your YouTube account. A notification will appear inviting you to link your AdSense and YouTube Accounts. Enter your Adsense account information as requested.
Wait for an email from YouTube confirming the accounts have been linked.
Log into YouTube, and click on a video. A new "Enable Revenue Sharing" button will be below your video. Click it, then a new page opens.
Submit the requested information verifying your ownership of copyrights and ability to use the video for commercial purposes, then click "Submit."
Wait for your video to be approved for revenue sharing. Then see the AdSense ads on your video.