php – Display ACF on Shop page

I need to display a value using ACF on my WooCommerce Shop/Product Archive page. I tried adding <h2><?php the_field('title'); ?></h2> to archive-product.php, but this did not show.
Then tried adding to functions.php, but also this did not display in my shop page.

function show_title() {
global $product;
$id = $product->get_id();
$title = get_field('title',$id);
if ( $title ) { 
    echo '<span>'.$title.'</span>';
add_action('woocommerce_after_shop_loop_item_title', 'show_title', 3 );