Back to Top in Html(Jquery)

HTML wise all we need to do is add a “back to top” link at the bottom of the blog post

Below Jquery code add in your header file:

<script src=""></script>
jQuery(document).ready(function() {
    var offset = 820;
    var duration = 700;
    jQuery(window).scroll(function() {
        if (jQuery(this).scrollTop() > offset) {
        } else {

    jQuery('.top').click(function(event) {
        jQuery('html, body').animate({scrollTop: 0}, duration);
        return false;

Below code add in footer file means end of page:
<a href="#" title="Back to Top" >Back to top</a>