Hello Friends, Now a days every one want to know that how to show hosted adsense ads on custom domain. So today I want to share that how to show adsense ads on custom domain. It is not difficult to show hosted adsense ads on custom domain. You first need to create blank blogger template and put the adsense code on the blogger template.
Download Blank template here : Download
How to Install Template.
Go to blogger dashboard
Create a new test blog
Give it title and address
Choose any template but simple is good
Next Blog >> Template >> Edit HTML
here is the code of Template
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html>
<html b:version='2' class='v2' expr:dir='data:blog.languageDirection' xmlns='http://www.w3.org/1999/xhtml' xmlns:b='http://www.google.com/2005/gml/b' xmlns:data='http://www.google.com/2005/gml/data' xmlns:expr='http://www.google.com/2005/gml/expr'>
<head>
<meta content='IE=EmulateIE7' http-equiv='X-UA-Compatible'/>
<b:if cond='data:blog.isMobile'>
<meta content='width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0' name='viewport'/>
<b:else/>
<meta content='width=1100' name='viewport'/>
</b:if>
<b:include data='blog' name='all-head-content'/>
<title><data:blog.pageTitle/></title>
<b:skin><![CDATA[/*
-----------------------------------------------
Them name : Blank blogger template
----------------------------------------------- */
#navbar-iframe { height:0px; visibility:hidden; display:none }
body {
font: $(body.font);
color: $(body.text.color);
background: $(body.background);
padding: 0 $(content.shadow.spread) $(content.shadow.spread) $(content.shadow.spread);
$(body.background.override) margin: 0;
padding: 0;
}
]]></b:skin>
</head>
<body>
<b:section class='navbar' id='navbar' maxwidgets='1' showaddelement='no'>
<b:widget id='Navbar1' locked='true' title='Navbar' type='Navbar'/>
</b:section>
<!-- Your adsense code here -->
<div style='margin-top:400px; '>
<!--Please keep the Credits intact-->
<center><p><a href='http://www.coolbloggertricks.com'>Cool Blogger Tricks </a>© 2013.</p></center>
</div>
</body>
</html>
Create a new file in your server file manager with extension .html
add this code in the file.
iframe1
<iframe src='http://yourblog.blogspot.com/' width='1100' height='1100' marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling='no'></iframe>
and the last step is that to add the iframe in the custom domain.
add this code where you want to add adsense code.
iframe2
<iframe src='http://yoursite.com/abc.html' width='336' height='280' marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling='no'></iframe>
Note : in iframe 2 you can change the height and width size with your own ad unit size.
You are Done. :)
You are Done. :)
Happy Earning,,










Nice Tips Dear Thanks For share :D
ReplyDeleteThanks for Visiting,,
ReplyDeleteNice Trick Brother :)
ReplyDeleteGood Work
Thanks for Visiting,,
ReplyDeleteWell thanks for the nice trick
ReplyDeleteReally nice broo great job :)
ReplyDeleteThanks for Visiting..
ReplyDeleteimran, this adsense enabling method on costum websites, be literarily, made my search to reach the destination. This is the adsense trick which i was searching for :)
ReplyDeleteThanks for Visiting..
ReplyDeleteWhere is the post? Only About The Author is showing
ReplyDeleteDear Shiraz, The issue is resolved.
ReplyDeleteI am sure this post haѕ touched all the internеt users, its rеally really nice ppost oon building
ReplyDeleteup new weblog.
Is it against adsense policy?
ReplyDeleteNo.
ReplyDeleteAlways found great work on this Website. Thanks admin <3
ReplyDeleteThanks for visiting..
ReplyDeletehello Imran.
ReplyDeleteThanks for sharing great stuff with us. I will applied this trick on my blog.
"Create a new file in your server file manager with extension .html " will you please explain this line?????
ReplyDeletego to your cpanel and then go to file manager where your files are hosted on the server and create a new file as cbt.html and edit it and paste the following code "" change the src with your blog url.
ReplyDeletecan you plzz tell me how to change your add script with mine ad code
ReplyDeletethanks in advance.
Edit Your blogger template and replace adsense code with your adsense code.
Deletethanks for fast replying but
Deletethis process is not working with my wordpress blog
i will add iframe code but my wordpress blog will not show any thing
but the same code is working on the blogger template and show ads....?
i am waiting for your reply...!!!
Ads showing on your blogspot blog ?
DeleteIf ads are showing on Blog then ads must show on wp blog also. Try again and tell me I'll help you.
yes ads was shown on blogspot.
Deletebut your blank blog ad was not working on wordpress
when i change blogadress in iframe code to any other blog or some random site
then that will show on my wordpress site in a square frame
but your blank blog with adsense was not shown...?
Contact me at Facebook
DeleteThis comment has been removed by a blog administrator.
ReplyDeletei want to know how to set Hosted Adsense on only Domain redirected blog?
ReplyDeleteWhen you add iframe code of your blog in your file manager of your website.
ReplyDeleteYou add iframe where you want to add adsense code. as
http://coolbloggertricks.com/abc.html
abc is the file name in your file manager.
If you apply all the steps carefully then it must show ads on custom domain.
ReplyDeleteHi brother this is not working. after pasting codes in templates ads not showing
ReplyDeletethis is superb trick and very usefull bro
ReplyDeletethanks for sharing but this is not working in wprdpress.. ads not showing bro pls help
If you use it carefully then it works. You need to create a blog and add blank template in blog and put your ads in template. When ads show on your blog then step 2 and step 3 and done. Try again. If you fail then tell me I'll do it for you.
Deleteplease how do make in my blogger blog is not showing after pointing my domain my blogspot
ReplyDeleteFollow these steps then adsense ads will be show.
DeleteAm using Blogger Not Wp how do i Create a new file in your server file manager with extension .html blogger
ReplyDeleteYou can use free server like 000webhost to use that step
DeleteOK Thanks I will try it
ReplyDeleteWhich Step you didn't understand ?
ReplyDeleteHi Imran Murtaza, This post very interesting.
ReplyDeleteBut if we use frame to show ads, are we violations of the tos?
Dear Henry YooRich,
DeleteRead Adsense Tos and then use this method or not. it is your own choice.
@Imran,I commented that I did not understand but when I read again, I understand how easy the tutorial is and why people fail to understand is because Mr Imran wrote it for people who are familiar with codes.
ReplyDeleteThanks for the tutorial, now it works for me but my question is. How can I show different ads sizes? How can this be done?
Thanks in advance.
Dear Donvin,
DeleteIf you want to add different size ads, you need to create new blog with new ad size unit and also create file in filemanager.
Dear Imran will i have to submit my worpress site in google adsense sites box or only blogger?
ReplyDeleteYou Just submit your blogger blog in adsense.
DeleteThanks Man.I have tried your mathod and its working for me on my site.
ReplyDeleteYou're Welcome.
DeleteNot Support Adsense New Code Pls Help me..
ReplyDeleteImran Brother I have question.first read below
ReplyDelete"To update your robots.txt file to grant our crawler access to your pages, remove the following two lines of text from your robots.txt file:
User-agent: Mediapartners-Google
Disallow: /"
I found The above lines which are in "" on google support forum.Dear We are using your mathod and it;s working fine but If I Do above changes in my robots.txt file then it can be dangerous or not?I mean adsense hawk eye because I am using your iframe mathod.Please Guide Me as soon as possibe.
Where do I add the second iframe?
ReplyDeleteWhere you want to put adsense code.
Deletebro kia yeh trick abhe bhe kaam kar raha hai ?
ReplyDeleteHi Imran Murtaza,
ReplyDeleteThis is a very useful trick, I've tested it but ads won't show when I put ad Code type: Asynchronous like this: script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js" it only shows ads if I put ad code type: Synchronous like this: script type="text/javascript"
As I said the code type is Synchronous, ads show on my custom domain is very small! How can I fix it???
Many thanks in advance!
First of all use Sync code like this
Delete< script type="text/javascript">
< /script>
< script type="text/javascript"
src="//pagead2.googlesyndication.com/pagead/show_ads.js">
< /script>
Remove this from first line
The code will become like this
< script type="text/javascript">
google_ad_client = "ca-pub-yyyyyyyyyyyy";
/* 336 */
google_ad_slot = "8067463888562";
google_ad_width = 336;
google_ad_height = 280;
< /script>
< script type="text/javascript"
src="//pagead2.googlesyndication.com/pagead/show_ads.js">
< /script>
Now ads show full size which you choose.
As I said, I put the synchronous but ads not show full size, ads only show small size with text only! Please see the following image you will understand what I want to talk about:
ReplyDeletehttp://imgur.com/delete/zp4h7R9ipmdq7Ow
Thank for your replying!