Add the following code to the functions.php of your child theme (download a free blank child-theme here).

Enable Infinite Scroll in Supported Themes

(try this first)

add_theme_support( 'infinite-scroll', array(
'container' => 'content',
'footer' => 'page',
) );

You may have to activate infinite scroll in the Jetpack plugin.

Enable Infinite Scroll in Unsupported Themes

function mytheme_infinite_scroll_init() {
add_theme_support( 'infinite-scroll', array(
'container' => 'content',
'render' => 'mytheme_infinite_scroll_render',
'footer' => 'wrapper',
) );
}
add_action( 'init', 'mytheme_infinite_scroll_init' );

function mytheme_infinite_scroll_render() {
get_template_part( 'loop' );
}

 

Infinite Scrolling is Still Not Working

If you can’t get infinite scrolling to work with the code above, don’t fret! It just means your theme hasn’t been coded like many newer themes to support infinite scrolling.

You may want to check out this solution by developer Samuel Wood, aka Otto, which explains how to separate your posts from the WordPress loop so you can enable infinite scrolling. It’s a solution that assumes you’re familiar with PHP, so only check it out if you’re comfortable with code.

Source: https://premium.wpmudev.org/blog/how-to-add-infinite-scrolling-to-your-wordpress-site/