Float AdSense and other Ads on left or right side of your Blog

A special widget that designed for floating AdSense and any other third party Ads on left side or right side of any Blog side.

Floating ads is effective when you don’t have enough space on your blog. 

Generally we can see our blog’s left and right side always vacant which is known as idle space and we can easily utilized those gap by using floating technique that can generate more click on AdSense ads. 

This will not occupy your valuable space from your blog content space or sidebar, footer section. 

In this tutorial I will share how to use "160px X 600Px"AdSense ads can be float right or left site of your blog. Not only AdSense ads can be float you can use any affiliates ads to make float.

Float AdSense and other Ads on left or right side of your Blog
Float Any Third Party Ads 

Oh before proceeding please read carefully about Terms of Service of your respective Affiliates ads network that are they allow to float ads or not?

Do you want to Float Dual AdSense and other Ads on left and right side in your Blogger site at a time? Then Please visit below URL.
1. How to Float 2 Wide Skyscraper Ad banner on Left and Right Side?
2. Float 300px X 250px Advertisement Middle of Blogger Site
3. Add 2 in 1 Floating Facebook and Advertise widget in Blog Site

Live Demo

Step #1: Log in to your Blogger account and Go to your Blogger Dashboard

Step #2: Go to your "Layout" tab.

Step #3: Click on "Add a Gadget" then select "HTML/JavaScript" Gadget.

Step #4: Now Copy the below code and Paste it in "HTML/JavaScript" Gadget.

#bloggerspicesflotads {
background: #333333 url('..');
border-bottom:2px #333333 solid;
border-right:2px #333333 solid;
border-left:2px #333333 solid;
border-bottom:1px #005094 solid;
border-bottom:0px blue solid;
<script type="text/javascript">
function getValue()
document.getElementById("bsadsheadline").style.display = 'none';
<div id="bsadsheadline">
<div id="bloggerspicesflotads">
<span style="color:#fff;font-size:13px;font-weight:bold;text-shadow:black 0.1em 0.1em 0.1em"></span>
<span style="color:#fff;font-size:13px;font-weight:bold;text-shadow:black 0.1em 0.1em 0.1em;float:right;padding-top:3px;padding-right:10px"><a href="http://www.bloggerspice.com/2013/05/how-to-float-adsense-and-other-third-party-ads-on-left-or-right-side-of-the-blogger-template.html" target="_blank" onclick="getValue()">close(x)</a></span>
<div id="bsadsbase">
<p align="left"><h3></h3></p>
Ads code here


  • Replace "Ads code here" with your AdSense or others ads code.
  • Change "160px" to increase or decrease wide
  • Change "Left" with right to float right side of your blog.

Obviously this widget will increase your ad revenue dramatically. Because this floating widget will easily attract the visitors to click on it. 
Ankit @ Blogger Tips Tricks says: 5/10/2013

Bro is it ok to use floating adsense ads? I think it's against Google adsense TOS.

Mohammad Fazle Rabbi says: 5/11/2013

I am not sure about it. If you have any proof then kindly share the link of Google TOS. However it can be use for other affiliated ads.

Kang Farhan says: 5/11/2013

thanks for article ...nice blog

Ankit Kumar Singla says: 5/12/2013

No dear I have not such a proof as I am also not damn sure about it. but yes we can use it for other advertising programs.

Mohammad Fazle Rabbi says: 5/12/2013

Farhan bro you are always welcome

shakeel asghar says: 5/12/2013

brother its against google adsense policies. your google adsense will disabled in 1-2 month because you have not permission to add adsense in popup box in your blog. it's against of google adsense Terms and Conditions i just inform you otherwise as you wish
for more visit this link : http://www.google.com/help/nopopupads.html

Blogging tips and tricks

Mohammad Fazle Rabbi says: 5/12/2013

thanks for your valuable sharing with us...

Dixit Dhinakaran says: 5/19/2013

Very useful! How can i remove the border? Please publish the code without border

Mohammad Fazle Rabbi says: 5/20/2013

border-bottom:2px #333333 solid;
border-right:2px #333333 solid;
border-left:2px #333333 solid;

Please replace the above code with below code-

border-bottom:0px #333333 solid;
border-right:0px #333333 solid;
border-left:0px #333333 solid;

Ravi Kumar says: 5/21/2013

Google Adsense doesn't allow you to use Pop-Up Ads so it is harmful for bloggers. Anyway nice work dude..Keep blogging

Mohammad Fazle Rabbi says: 5/21/2013

right bro...but this widget has designed for all ads network. So blogger can use for any affiliate ads.

MM NAUMAN says: 5/28/2013

hello again i want the ad to show in right side of my blog but it is coming in left side only i have changed from left align to right align but the ads are displaying in right direction only please reply fast...........

Mohammad Fazle Rabbi says: 5/28/2013

thanks for your comment I just modified the code change left:10px; to right. I have highlighted above..

MM NAUMAN says: 5/28/2013

Thanks Brother For Visiting My Blog ..................Please Say Me It Is good?????????

Anonymous 6/04/2013

this works great, thank you. The close button doesnt work, can you let us know how to use this feature? I want users to be able to close the ad if they want.

Mohammad Fazle Rabbi says: 6/04/2013

its working well..till now this widget is using more than 25+ site. Anyway give me your site address I will check it to solve the problem.

zeeshan says: 7/03/2013

i add but it shows small its adress take a look i want to float it likes yours big one


Mohammad Fazle Rabbi says: 7/04/2013

Zeeshan I have visited this site but didn't get any floating ads..kindly add it and comment here. then Hopefully I can give you solution.

khorshed alam says: 7/19/2013
This comment has been removed by a blog administrator.
Furqan Haider says: 7/31/2013

Great Widget

Mohammad Fazle Rabbi says: 7/31/2013

thanks Furqan..Nice to see u back here

Ryo Alkatiry Squiddy Aurrorra says: 8/06/2013

thanks brother, hehehe :D
visit here http://kang-rio.blogspot.com

Mohammad Fazle Rabbi says: 8/07/2013

Hi Ryo nice to see you here first time.Thanks for commenting.

Anonymous 8/13/2013

Hello Muhmmad Fazle I Want To Know About Doamin And Hosting Of Websites Can U Plz Contact Me At tareen5152@gmail.com Plz Plz Bropther

zeeshan shah says: 8/14/2013

brother please make a new widget for vertical banner like this and for closing that widget i dont want a redirect thanks i am daily visitor of your site because it help me much

Mohammad Fazle Rabbi says: 8/17/2013

Hi Zeeshan..thanks for your comment. It is very hard to create an widget. After spending several hour I have created this.I think it won't bother any visitors of your blog. This is just a credit to authors.Those who are interested about ads they would click on it not in close button. Beside of this it won't hamper your page rank. Thanks

Mohammad Fazle Rabbi says: 8/17/2013

Hi Ameer..I was in holiday for 10 days. Please write me details what do you want to know? I have explain about domain and hosting details in many articles.Anyway I am explaining clearly...

Domain is just a name which you can buy within $7 to $10. and
Hosting is a place where your blog will retain. For example..BloggerSpice.com is a domain name. And I am using Google Blogger as my hosting. Everything of my web data pictures has stored on Google Hosting site.

Himadri biswas says: 8/24/2013

I am also confused about it. Although I am going to use this code to
If it is really against the Google adsense TOS then it will be bad for me. But thank you Rabbi.

Mohammad Fazle Rabbi says: 8/24/2013

Thanks Himadri to see u here.

उदयन पी.के. तुळजापूरकर
एक भारतीय
Udayan P.K. Tuljapurkar
says: 2/05/2014

i visited maximum sites but you are the only true person who given the javacode here. thanks for the great job you have done and sharing to others.

Mohammad Fazle Rabbi says: 2/06/2014

Thanks Mr. Udayan..always I try with my best effort to make some creative and unique coding for my blog readers. And you are always welcome to BloggerSpice. And thanks again for your comment.

उदयन पी.के. तुळजापूरकर
एक भारतीय
Udayan P.K. Tuljapurkar
says: 2/06/2014

Dear Mr. Mohammad i need a help from you i have a blog, http://blogs-in-blog.blogspot.com, please check this and suggest me for getting more revenue from my blog.

Mohammad Fazle Rabbi says: 2/06/2014

Mr. Udayan..From my 4 years personal experience in blogging I have learned 1 thing that Google is my friend and others are enemy. I have used many affiliates but didn't work, most of the affiliates are fake. So keep Google ads only nothing else. Because you won't get any payment from them. Beside of this make regular post and soon I am starting a new series on AdSense optimization for generating more revenue from next week. Hope that will work.

उदयन पी.के. तुळजापूरकर
एक भारतीय
Udayan P.K. Tuljapurkar
says: 2/06/2014

Right now I am using Adsense, clickbank.net, Amazon.in, will the other two sites won't pay me ?, another question is in my one blog, i can share the blog post on Facebook, but in another blog i won't able to share the post. sharing possible is on http://health-blogs-in-blog.blogspot.com, and not possible on http://blogs-in-blog.blogspot.com, can you able to tell me what is the problem.

Mohammad Fazle Rabbi says: 2/06/2014

Use only AdSense...Because if you have more ads then ur visitors won't like to visit the site. Another thing in case of Payout, suppose Google won't pay you until ur total revenue reach to $100. So if you use 3 affiliate ads then total impression will split into 3. As a result it will take more than 1 year to make $100.

Another issue is Facebook this is a great problem for every blog. Because when you try to share something then posts image thumbnail will display different image or unrelated image, For this reason you can use auto sharing technique through third party plugins. Please follow the below tutorial---


But before that you can try Opera Browser..it work best. I have tried to share though Opera it is able to display relevant image on Facebook while I share.

Md.Goljar Ali says: 5/24/2014

I am sure that It's completely against the rules of adsense

Mohammad Fazle Rabbi says: 5/25/2014

Yeh you are right this is against Adsense rules. But this tutorial not only for AdSense..You can use any other Ads code to display.

Gurudumu la habari says: 6/08/2014

hi bro.. i put it but it does not show anything but the displayed

Mohammad Fazle Rabbi says: 6/09/2014

Hi Habari..This widget work 100%...I think you have modified any code. There are many user modify the code and eventually it doesn't work. You can check the demo of this widget.

priyanka reddy says: 6/20/2014

Bro I need your help .where to register domain name at free of cost to remove my blogspot keyword in blogger.and which is best hosting service at free of cost

Mohammad Fazle Rabbi says: 6/22/2014

Ho Priynka..there are many free domain name provider available over the net. such as.. .tk CO.NR .co.nf......but be carefull about those because they reserve all rights to remove the domain name service without any notification. Thanks

Abhishek Sharma says: 8/05/2014

Hello Bro...
Tell me how to insert this code in the bottom of the page... i mean i want to float 768x90 ad in the bottom of my page.down side.

Mohammad Fazle Rabbi says: 8/06/2014

You have to change several things to do this. first you have to change the width and height code height:600;

Secondly change left:10px; with bottom:10px


Maribel Nuarin says: 9/05/2014

When I click on close it doesn't close the ad but it just stay in the sidebar. what should i do?

Mohammad Fazle Rabbi says: 9/07/2014

Hi Maribel..This widget has redirect option to main author site. And close button is working 100%. I think you have get this code from BloGs911. He has copied my code maybe for this reason you face trouble, I am the original author of this code. You can try the code from above. Thanks.

Maribel Nuarin says: 9/11/2014

Yes, I did try to put your code in my blog, but when I try to add it, Yes is in there, but when i click the button it doesnt exit. It is still in there.

Mohammad Fazle Rabbi says: 9/11/2014

Hi Naurin...I just checked your blog it is working fine. And closing ads. I didn't find any problem. You can also check this widget by clicking on "Live Demo" button.

Rashedul Islam says: 10/26/2014

Awesome post bro, i searched in many place and was unable to find this....and finally got this thank you bro......

Mahbub Hasan says: 2/08/2015


Mohammad Fazle Rabbi says: 2/08/2015

Welcome Bro..

Mohammad Fazle Rabbi says: 2/08/2015

Thanks Mahbub

Sambhav jain says: 2/21/2015

hey Mohammad Fazle Rabbi tell me how to remove the floating widget from my blog?? ??

Mohammad Fazle Rabbi says: 2/21/2015

Hi if you have added the code then simply delete the added code from the widget. That's it. floating widget will be remove.

Admin says: 2/26/2015


Please let me know the floater code which closes only after clicking advert


Mohammad Fazle Rabbi says: 2/26/2015

Hi there... I have designed altogether 3 floating widget for displaying advertisement.And you will find close sign at the top right of the floating widget. After clicking on there ad will be automatically close. Thanks

Mohamed Sawah says: 3/01/2015

thank you brother
please visit me: http://www.3rabcloud.com

Mohammad Fazle Rabbi says: 3/01/2015

Assalamu Alaikum Mr. Sawah, Thanks for using this widget.

Junel Ponce says: 3/21/2015

Hi Thanks for this wonderful stuff.

I was reading your blog this morning and noticed that you have a awesome resource page. I actually have a similar blog that might be helpful or useful to your audience.

See it yourself: JRPCollection.blogspot.com

Let me know what you think of it. Perhaps it’s worth mentioning on your resource page.

Either way, have a nice day,

Mohammad Fazle Rabbi says: 3/21/2015

Hi Junel, your site is very good but make more post. Thanks

Juelur rahman says: 3/24/2015

Thanks a lot for a great sharing. Best suggestion for adsense.

Mohammad Fazle Rabbi says: 3/24/2015

Hi Rahman..Please use this widget with AdSense at left sidebar or right sidebar only. Some user place this widget above the post snippet thus a visitors must click on the ad for view the content. This is totally violation of Google AdSense's terms and condition.

avnish gautam says: 4/15/2015

Adsense floating ads is very effective to show ads on our desired places. Thanks for guide about

Mohammad Fazle Rabbi says: 4/17/2015

Welcome Avnihs..

V says: 5/25/2015

My study period = 15 minutes. My break time = 3 hours.
Status for Facebook

akshay rohida says: 7/09/2015

let's try this , it may attract readers

Sandesh Chauhan says: 7/27/2015

hello can you plz tell me how to add adsense in middle of the post??

Mohammad Fazle Rabbi says: 7/28/2015

Hi Sandesh.. please follow the below tutorial...take a backup before applying this trick. ^_^


Sandesh Chauhan says: 7/29/2015

thanks for your reply and can you also tell me is there any way to show float adsense only in mobile devices in the bottom??

Mohammad Fazle Rabbi says: 7/29/2015

Sorry Chauhan there are not any different conditional tag for mobile device thus ad can be shows only on mobile devide. :t

AmartDein says: 8/31/2015

Thanks a lot for a great sharing. I want it appear on both left and right side of my blog. Could you tell me how should I modify the code?

aman ngoma says: 10/11/2015

Hi. I have a problem in getting ads code, may you help me how to get it please?

Mohammad Fazle Rabbi says: 10/12/2015

Hi Aman.. Whats your problem? please write me.

Cartoon Media says: 10/14/2015

Bhai main picture kay uper ads lagan chata hoon kaisy lagey ga meri help karein please

Mohammad Fazle Rabbi says: 10/14/2015

Actually your question is not clear. In which picture you want to set ads. Anyway you can follow the below link for tutorial for adding Ads above post title inside Blog post.


Anonymous 12/11/2015

Google Adsense codes are not allowed to shown as Floating ads

Mohammad Fazle Rabbi says: 12/11/2015

You will able to display any kids of ads by using this widget. Not only Google AdSense. However if you can float the adsense code on safe position (not over the content or widget) then it won't violate AdSense terms and condition.

Manbahadur Kc says: 1/22/2016


Mohammad Fazle Rabbi says: 1/22/2016

Hi Manbahadur, I think you have used HTML5 symbol, but unfortunately it doesn't support my comment system. But I have seen in moderation tab. Its nice Thanks.


Tùng Unlock says: 3/04/2016

Nice coding ! but i think we should use an other advertisers, because I think it would violate laws of GA.I tried this code and receive alerts from the GA about not optimized.
my website http://www.ios-faq.com . I just put ads at the 3-position static, that is enough. I think so

Mohammad Fazle Rabbi says: 3/04/2016

Hi Tung, :wr This is absolutely true that Google AdSense code modification is now allowed. But if you are using 960px width template then you can use it. But if you force visitors to click on your ads then it will violate the AdSense terms and conditions. But this widget is ideal for using other advertising companies ad banner.

Vishvesh Mishra says: 4/06/2016

The code works flawlessly on my blog http://vishveshtech.blogspot.in/
I'll be using it for third party ads and not Google Ad Sense so it shouldn't be a problem I guess.
Keep up the good work.

Mohammad Fazle Rabbi says: 4/07/2016

Hi Vishvesh, Thanks for using my widget. :up

santanu achar says: 5/05/2016
This comment has been removed by a blog administrator.
Mohammad Fazle Rabbi says: 6/17/2016

Hi Jeyaganeshan Jeyakeethan,
Your widget is completely different than mine. Anyway thanks for commenting. And note that any hidden URL won't appear in my Blog's comment section. So next time don't share hidden URL. :up

chukwudi ezie says: 6/19/2016

It's there a way I can stop it from redirecting? My readers Complains of that each time they click close

Mohammad Fazle Rabbi says: 6/19/2016

Hi Chukwudi
I have added a credit URL with this widget but it doesn't redirect your Blog to my Blog. rather it will open the widget page at the background. however you can remove this http://www.bloggerspice.com/2013/05/how-to-float-adsense-and-other-third-party-ads-on-left-or-right-side-of-the-blogger-template.html URL to stop redirecting.


Aji says: 6/21/2016

Thank's for the script.I have been put it on at my site
Omah Cetak

Mohammad Fazle Rabbi says: 6/22/2016

Thanks Aji for using my widget. :up

Srinivas says: 6/29/2016

Saved my day. Thanks for the wonderful article.

Mohammad Fazle Rabbi says: 6/30/2016

I am very glad to hear that Srinivas.. Wish you best of luck in your Blogging career. :up

chukwudi ezie says: 7/01/2016

Hey, thanks very much for reply,but after removing the credit link, when you click on close,it reloads page , it doesn't close, is there anything I can do?

Mohammad Fazle Rabbi says: 7/01/2016

I didn't find this kinds of problem. I think you are using any popup affiliate ads in your site that's why it is conflicting. You can test the widget in different browser or alternatively you can use my another widget from below URL- :wr


Susana Keyman says: 8/27/2016

Brother , This Ads Code Works On One Side, Please Share Code Both Showing Both Side Ads,

Individually One Side R Working Fine, Even I Use Is for Right And Left , But Both Side R Not Working ,

Mohammad Fazle Rabbi says: 8/28/2016

Hi Susana,
I have already shared widget for both side floating advertisement. Please visit below URl for widget script. :sp


gaurav vashisht says: 9/10/2016

great widget

Mohammad Fazle Rabbi says: 9/11/2016

Thanks Gaurav :sp

Han Kaltrunee says: 9/25/2016

How to make ads responsive and place them right below the post title in blogger?
Thanks for sharing this informative post.

Mohammad Fazle Rabbi says: 9/26/2016

Hi Han Kaltrunee,
Currently Google AdSense, Media.net and some other ad agency providing responsive ads. So if you get approval from Google AdSense then you can use Responsive ad unit on your Blog. :wr

Awais says: 10/16/2016

Nice article about AdSense. Bit Mr. Ankit tense me about this by telling this is against AdSense TOS?

Mohammad Fazle Rabbi says: 10/17/2016

Hi Awais,
Yes this widget violate the terms and services of AdSense. but you can use this for other advertising platform. IF you want to use this widget for AdSense then you should use it for your own risk. However I have seen many website using this widget for 1 year but Google still didn't penalize.

Awais says: 10/18/2016

but brother new blogger if use then Google penalize immediately. I also saw but all sites was contain big traffic.

Mohammad Fazle Rabbi says: 10/18/2016

Yes right. Most of the Blog using this widget who has got AdSense approval 2/3 years ago. But if the ad banner don't cover any post then you can use it. Most of the use place the ad banner where visitors can't see the Post title or image. As a result they must click on the ad for reading the post. For this reason Google penalize. As result visitors are bound to click on ads.

Awais says: 10/18/2016

I agree.

Jyotsna says: 4/19/2017

It's safe pls suggest

Rabbi Khan says: 4/20/2017

Hi Jyotsna ^_^
Google AdSense doesn't allow any modification and tweak on their ad banner. So if you want to use this widget then you have to use this by your own risk.

But any other ad platform you can easily use this widget. Thank you.

Jyotsna says: 4/23/2017

Thanks for good artical


Alex says: 5/08/2017

Thank you so much for this tip.

Rabbi Khan says: 5/09/2017

:-bd Welcome Alex. I hope this would help you to place ads on our blog's sidebar.

Naveed says: 5/16/2017

Thanks for this wonderful trick.
I already knew but you explained in more details.
greeting from INDIA.

Rabbi Khan says: 5/17/2017

Hi Naveed :)
Thanks for your lovely comment.

Mohamed says: 7/10/2017

thanks for the tips. useful for newbies like me for blogging success rate. i have bookmarked your blog for future use. thanks!

Assurance Auto Résilié
assurance auto malus

Rabbi Khan says: 7/16/2017

Hi Mohamed :) I am very glade to hear that.

kavita says: 7/26/2017

Google Adsense does not allow scrolling of ads. If you are caught, you will be banned.

Rabbi Khan says: 7/28/2017

Hi Kavita
Yes right, I recommend this widget for other ad platform. AdSense users have to use this widget in his own risk.

Aashirvad Kumar says: 12/21/2017

Thanks for letting us know about the things. These are really helpful for all.

Bellvania Aleyza says: 3/06/2018

Join And Be A Winner with us

Rabbi Khan says: 3/20/2018

Awesome :up

Sumit Kumar Gogawat says: 3/22/2018

Actually Google Adsense banned your account to floating ads. Only premium publishers allowed to show floating ads.

Rabbi Khan says: 3/26/2018

Hi Aashirvad Kumar

Thanks for your lovely feedback :up

Rakesh Kumar says: 7/31/2018

Thank's for the script.I have been put it on at my site.

Blogger Spice says: 8/05/2018

Great! :dn

Adewale Aloko says: 9/11/2018

It actually increase my google adsense earnings after implementing it on my blog: https://www.goodbooksafrica.com

Blogger Spice says: 9/12/2018

Yes! Absolutely true. :up

JUDY BestView says: 12/11/2018

You are doing great work here!
Please, can you help me with related post code that displays on desktop view?. The one l added displayed only on mobile view. Visit my blog @ www.judybestview.blogspot.com.please help!thanks

GK Tricks By Manish says: 12/16/2018

Thanks a lot....Verymuch Helpful Article.

GK Tricks By Manish says: 12/16/2018

After Putting this code suddenly increased Earning in my blog i.e. www.sadupayog.com
Thanks a lot.

Contact Form


Email *

Message *