Add “Back to Top” link to your Blog Footer

by Imran Shariff on October 25, 2010

Sometimes we create a very appealing blog and ignore on some basic features. One of the features is “Back to Top” on your blog’s footer.  Blogs have a tendency to create huge scroll bars, whether that scroll bar is long because you dont use the more tag to cut down your posts, or you get a lot of blog comments, the matter of fact is, if you have huge scroll bar and no easy way to get back to the top, it will annoy the blog reader.

This is something so simple, when a user gets to bottom of the page and sees the link,  they click on the link or the image and they go to the very top of the page. This awesome feature is really very easy to create and very effective to your blog.

There are many way to add this feature in your blog, one of the easiest way is to use the plugin to do the job.  And if you don’t trust the plugin and have a basic knowledge of HTML and Javascript you have this tutorial as a back stand for your own blog.

Do check some of our hot Tutorials:

If you are looking to add it manually, I found one awesome article on the net which you might be interested.

  • A Short Story About “Back To Top” links from SmashingMagazine.com.

Just use this code and add it to your footer somewhere:

<a href="#header">Back to top</a>

If you like the Back to Top feature in this blog and want to implement  in your blog you can use the below code.

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js" type="text/javascript" charset="utf-8"></script>
<a class="top"></a>
<script type="text/javascript">$(function() {
$('a.top').click(function() {
$('body,html').animate({scrollTop:0},800);
});
});
</script>

For Thesis Theme users you can use the above code  by creating a function in your custom_functions.php file. I have add a sample thesis function for your reference.

function back_to_top() { ?>

<div id="footer">
YOUR FOOTER CODE AND BACK TO TOP CODE HERE...!
</div>

<?php
}
add_action('thesis_hook_footer', 'back_to_top');
remove_action('thesis_hook_footer', 'thesis_attribution');

Check our other awesome articles on Thesis theme:

It is very easy, simple and yet power feature, when the link gets clicked it automatically shoots to the top of the page.

Do share your thoughts and experience on using “Back To Top” feature and what method are your using in your blog.  If your like this tutorial do share with your friends and don’t forget Tweet and Stumble.

Happy Blogging !!!

View all posts by
Blog → Visit Author's Blog

Follow Us On

@shariffdotorg facebook

Article by Imran Shariff

Imran Shariff is a Full-time blogger, web designer and the man behind this blog who is working very hard to keep the quality. The only aim of starting this blog is to share all the knowledge and information by experimenting on various platform.

Imran has written 67 awesome articles for Shariffdotorg

{ 36 comments… read them below or add one }

hiru from Twebappdirectory October 25, 2010 at 7:38 am

Great suggestion. It will make our blog more user friendly. Thanks for the share.
Thiru@webappdirectory recently posted..Artigetcom – Study all interesting topicsMy Profile

Reply

Shariff October 25, 2010 at 5:36 pm

Yes Thiru,

It is a great little tool first it was very difficult to add this feature, but managed to do so…

Thanks for visiting by and commenting.
-Imran

Reply

Richard October 25, 2010 at 5:29 pm

Great tip! I hadn’t even thought of this feature and it’s such a simple idea. I’m going to take another look at my blog and see about adding a back to the top button.
Richard recently posted..Timesaver Tips- Gain Twitter Followers OvernightMy Profile

Reply

Shariff October 25, 2010 at 5:32 pm

Hi Richard,

It is very good feature it makes the blog more user friendly. You can see the example in this blog, I have already implemented.

Thanks for Commenting
-Imran

Reply

Sayed October 26, 2010 at 5:47 pm

Awesome Tips Imran,

I was using Java Script to have that same “scrolling to top” effect, but mine was a bit buggy, Thanks for including the code.

Sayed.
Sayed recently posted..What Is “NoDoFollow” And How To Identify ItMy Profile

Reply

Shariff October 28, 2010 at 4:40 am

Thanks Sayed, and glad u liked it. Even I was searching the net for a very long time.

Thanks for commenting.

-Imran

Reply

Bilal Ahmad from WP Plugins Blog October 27, 2010 at 9:37 am

Very useful tutorial. Footer is a of course very useful area of a blog where you cans how basic information and this button can save readers time.

Reply

Shariff October 27, 2010 at 1:33 pm

Yes Bilal you are very right and agree with you.

Thanks for visiting by and commenting
-Imran

Reply

vijay | bayofblog October 27, 2010 at 1:22 pm

People easily navigate the blog which they accessing through this back to top and this will improve the visitors to return our blog…

Reply

Shariff October 27, 2010 at 1:27 pm

Yes Vijay, you are very right even small basic features will improve the blog performance.

Reply

iPhone Development October 28, 2010 at 6:08 am

Kudos!! Simple, cool and useful tip. Thanks a ton.

Reply

Shariff October 29, 2010 at 3:09 am

Thanks for stopping by and commenting.
-Imran

Reply

Vijayraj Reddy October 28, 2010 at 4:49 pm

i prefer easy scroll plugin..
Vijayraj Reddy recently posted..How to Add PayPal Donate or Buy Button to a WebsiteMy Profile

Reply

Shariff October 29, 2010 at 3:08 am

Hi Vijayraj, I alway prefer this over using a plugin. If I can do this simple job placing code then why use plugin.

Thanks for Commenting.
-Imran

Reply

Biodun from UK ecommerce forum November 2, 2010 at 9:52 am

And also remember Vijayraj, the more number of plugin enabled the slower your site so why not using a simple code?
Biodun @ UK ecommerce forum recently posted..Google Violates Privacy with Steet View Wi-fi data collectionMy Profile

Reply

Madav October 28, 2010 at 10:13 pm

Hi Imran,

I am going to try it on one of my blog.I am expecting your help if I got stuck some where.
Madav recently posted..Report spam website’s using Google spam report extensionMy Profile

Reply

Shariff October 29, 2010 at 3:04 am

Do try it Madav I am always here to extend my help.

Reply

Patricia from lavenderuses October 29, 2010 at 11:37 am

Hi Imran
I have seen on other blogs where there is plenty of information in the footer. I
want to eventually do that. Thanks for the helpful information.
Patricia Perth Australia
Patricia@lavenderuses recently posted..Lavender Products-cheap but not so cheerfulMy Profile

Reply

Praveen-Techperk October 29, 2010 at 1:33 pm

Great share, cool
i love your site
Praveen-Techperk recently posted..25 Top Free Android AppsMy Profile

Reply

jinkya from ABLOG404 November 5, 2010 at 12:20 am

Thats very cool tweak , I am just looking for more different creative scripts to match my blog;s theme and at the same time load super fast
Ajinkya@BLOG404 recently posted..15 Online Tools to Count number of characters from TextMy Profile

Reply

Sim So Dep November 5, 2010 at 1:53 am

This is the best information I have gotten all day. This would be a great feature to add to my blog. Thanks :)

Reply

Shariff November 25, 2010 at 6:29 pm

Thanks Sim, after a little hardwork I was able to put to gather..

Thanks for stopping by and commenting
-Imran

Reply

anuj from webtricks March 2, 2011 at 5:43 pm

thanks Shariff i am looking for that :)

Reply

Shariff March 2, 2011 at 5:59 pm

Yes Anuj is really very easy to add back to top feature in the footer of the blog.. Let me know if you required any help :) if in any case you feel difficulty.. More nice experiments with your blog using thesis theme..

Thanks for Stopping by and commenting
-Imran

Reply

anuj from webtricksblog.com March 5, 2011 at 9:59 am

Hi,Shariff

i added back to top button on my blog but its not working in Firefox any idea ?

Reply

Shariff March 5, 2011 at 1:38 pm

Hi Anuj,

It works perfectly on all browsers… try it once again you should have missed some thing.. however if you are unable to add solve I will be online on monday you can contact on via gtalk or skype my ID is shariffse@gmail.com

Reply

anuj from webtricksblog March 7, 2011 at 7:14 pm

yes You r right i miss one thing i am using a href=”#top”>Back to top
in place of Header :)
anuj@webtricksblog recently posted..How To Add Top Bar Or Header Bar In Thesis Theme Without Any WordPress PluginMy Profile

Reply

options trading April 7, 2011 at 6:28 am

Thanks for adding your valuable information here. Really nice of you. Keep in touch and have a nice day ahead.
options trading

Reply

Non Plagiarised Essay April 8, 2011 at 7:57 am

It’s really interesting to read this article here and the information is totally new to me. Thanks for this article…….

Reply

Shariff April 8, 2011 at 1:42 pm

Thanks for stopping by and commenting.

-Imran

Reply

Mike May 14, 2011 at 3:55 am

Thanks a lot! I used the #header code for my site and it worked perfectly.

Reply

Renee from free social bookmarking software December 24, 2011 at 10:21 am

I spotted that you brought up a common SEO software tool and thought it might be of interest to your audience that we have released our own free of charge social bookmarking and viral promotion software application. It works with a wide range of well-known social marketing platforms including Delicious. The software can be acquired through our web site. Please share this info with your followers.

Reply

koduleht February 8, 2012 at 9:51 am

Thanks! Great help for me, because one of our clients needed this kind of solution.

Reply

Blogging Tips March 2, 2012 at 10:25 am

nyc tips bro..You can also get nice tips to add back to top button for blogger on http://www.gulmiresunga.com/2012/03/add-back-to-top-button-on-your-blog.html
Blogging Tips recently posted..Add Back To Top Button On Your BlogMy Profile

Reply

PC Enthusiast March 28, 2012 at 5:19 pm

Thanks for sharing! I tried your “Back to top” button below this post, but it’s not working. I guess I’ll try the simpler one.
PC Enthusiast recently posted..Sony Xperia S, Xperia P and Xperai U Price and Release in Philippines announced!My Profile

Reply

Web Design May 16, 2012 at 10:22 am

thanks for sharing good information, now i will try this and i will make one Back to Top button for my blog with help of this tips.

Reply

Leave a Comment

CommentLuv badge

This site uses KeywordLuv. Enter YourName@YourKeywords in the Name field to take advantage.

Previous post:

Next post: