This is too complicated and not necessary as for example:
- Wordpress media library uses Wordpress thumbnail size,
- Wordpress blog and pages use some other Wordpress sizes,
- WooCommerce need its 3 image own sizes and to use just one will oblige you to override a lot of different Woocommerce templates (and will create problems in some core functions).
Also remember that for the different screen devices, different image sizes are used too. This make shorter loading time on medium and small devices.
Now you can use the code below to remove images sizes if you want to try and test (you should comment the image sizes you want to keep):
add_action('init', 'remove_plugin_image_sizes');
function remove_plugin_image_sizes() {
# remove_image_size('thumbnail'); // Wordpress (used by the media librairy to display thumbs)
remove_image_size('medium'); // Wordpress
remove_image_size('medium_large'); // Wordpress
remove_image_size('large'); // Wordpress
remove_image_size('shop_thumbnail'); // Woocommerce
remove_image_size('shop_catalog'); // Woocommerce
remove_image_size('shop_single'); // Woocommerce
}
Code goes in function.php file of your active child theme (or theme) or also in any plugin file.
I don't guaranty anything for WooCommerce as this is untested and the different image sizes are used in templates and functions, so you can have real problems.
You will have always the full size image (the original upload).
ACTIVATION:
You will need to switch your active theme to another and then switch back to activate it.
If it's a problem of weight, you can set small sizes for unused sizes in:
- Wordpress general settings > Media librairy
- Woocommerce settings > Products > Display
You should need to regenerate all existing images with Regenerate Thumbnails plugin
You can use also automated compression image tools like Smush Image Compression and Optimization plugin
Related answer: Disable original image crop in WooCommerce