What you need to do is to compress the image. WordPress offers a filter to set the compression ratio.
function my_jpg_compression($args) {
return 75;
}
add_filter('jpeg_quality', 'my_jpg_compression');
NOTE: What you are returning is the compression ratio. 70-80% is
manageable and you will not notice much reduced image quality. Also,
after applying this filter only future image’s size can be reduced and
not the one which are already uploaded.
What for already uploaded images?
You can use some awesome plugins to reduce image size and still keeping manageable quality. One of such a plugin is WP SmushIt. In fact you can use this plugin for future uploaded images too.
Related Posts:
- How do I delete all UNUSED images from my uploads directory?
- Did I do it right? Deleting images after deleting product. Woocommerce
- Woocommerce featured image of page – not product
- wordpress (woocommerce) add image to media library programmatically python
- Resize into square the single product image in woocommerce without cropping [closed]
- How to make footer area transparent? Using Avada and WordPress [closed]
- Product Images Low Quality After Updating From WP 3.5 to 4 [closed]
- Hide image gallery in Woocommerce if NO image [closed]
- When upload a PNG a noise appears in the thumbnails
- Exclude first image from a Woocommerce image gallery
- Why does wp_get_attachment_image_src return the wrong size, when the correct size exists?
- How to delete images from database with product
- WooCommerce Variation Swatches and Photos – get attribute thumbnail
- How can the alt be added to this wooCommerce category image?
- Bypass wp_safe_remote_get()?
- Image thumbnail on single product issue | WooCommerce
- How to get a list of all the possible thumbnail sizes set within a theme
- How do I get the avatar URL instead of an HTML IMG tag when using get_avatar?
- Image Upload from URL
- Is it possible set a featured image with external image URL
- Prevent WordPress from adding image’ title automatically
- Overide Gallery Default Link to Settings
- How to insert images into posts without using Add Media dialog
- How can I determine if a post has an image attachment?
- Img Src File path issue
- replace wp_get_attachment_image with my own function
- Images dont show in grid view, but do in list view
- Automating a Daily Picture Blog?
- Disable WordPress Big Image Size Scaling
- How to display a shortcode caption somewhere other than the_content
- Allowing post attachments without allowing to insert in text
- get attributes/part of the gallery shortcode
- extract post image to be featured images
- Sidebar slideshow widget [closed]
- Image file sizes increasing on upload
- How to Change WordPress Image URLs
- Different upload path per file type
- Animated Gif image not uploading correctly
- HTML tags in WordPress image caption
- How can I upload an image for background use using the Theme Editor in WordPress?
- Can an image have more than one parent_post?
- Where are the resized images coming from?
- unattached media files that should be attached
- Keep image EXIF info after compressing original image?
- How can I attach hotlinked images in posts/pages within the same server?
- WordPress Image Attachment using remote image
- Migration to WP – Couldn’t load image
- How can I create more upload paths, like a post corresponding to a post title folder used to store images of the same product
- Multiple amp-image overlays. How to properly do this in wordpress?
- Update an image block style programatically
- How to delete 1000s of duplicated images in WordPress?
- an error occurred in the upload. please try again later (Maybe File Permission Issue)
- Image Upload HTTP 500 Internal server error
- Animated GIF on WordPress posts? [closed]
- convert post title to image
- Can you check if a post WYSIWYG field has an image in it?
- how to put image and text on same line [closed]
- Different background images on different sites [closed]
- How to know what size image to use for background? [closed]
- Google Page Speed Insights – Optimize Images
- Is there a way in WordPress to convert images to WebP without a plugin?
- Partial img lazy load with WP 5.5
- Why doesn’t WordPress use the smaller sized image?
- Can’t see images in posts after migrating site to subdomain
- What is required in the hosting environment for WordPress to process an image into multiple sizes?
- Images dont show up on an iPhone [closed]
- Moving an image to the side [closed]
- Placing a featured image into header
- Function to grab specific image IDs from media library.
- image upload/edit is broken: “Image data does not exist. Please re-upload the image.”
- How can we upload common images only to AWS S3 using WordPress?
- Deleted Image giving a 301
- Avatar picture is broken
- WordPress append -1 to the image name
- wpdb function for filtering the images by title
- Link to products with the same image title (woocommerce)
- How to echo images Urls from a wordpress post, that are relally in the post
- Adding Post Thumbnail to Metro Pro Theme
- media_handle_upload() with 1 image under 1Mb chokes my server and returns timeout error
- WordPress does not load most theme images
- convert images and media url into blob url
- How to add featured image use HTML
- Correct color profile and saving? Thumbnail creation?
- New portfolio items appearing smaller on the grid
- Theme page headers and rotator images not assigned after website migration
- WPML – Change media uploader language
- How can I hook and edit on the fly an image uploaded
- Anomaly with response coming from XML RPC Api get Post (integer out of range)
- Create a custom attachment thumbnail for quick page load
- Change the image for a certain URL
- Using file extensions in image titles
- Media upload in add comment meta box
- Create post thumbnails from images stored outside of uploads directory
- php.ini -Theme-specific settings
- How do I insert a photo at the top of the sidebar?
- If image width bigger than height [duplicate]
- Site header logo and parallax image on homepage do not display on iPhone
- WP_Image_Editor – How to save the new size of the image in the sizes metadata
- Is is possible to append .webp to srcset images using wp_filter_content_tags()?
- Could a very long article slow down all website and wpadmin?