Paste the following code in your active child-theme’s functions.php:

/* Enable GIFs on single-product pages */
add_filter( 'woocommerce_gallery_image_size', function() {
    return 'full';
} );

Source: no source.