How to get the title of the blog page in WordPress

To get the title of the blog page you may use the get_the_title() function. Make sure you put the post page id as a parameter for the function. To get that id, use another function get_option() with two parameters: a page_for_posts variable and true. Your code may look like this:

<h2><?php echo get_the_title( get_option('page_for_posts', true) ); ?></h2>