Your Divi Blog Grid Is Serving 400px Images. Here Is Why
If the images in your Divi blog grid look soft, or keep cutting the top off somebody's head, it is not your photographs and it is not the theme being careless. It is one registered image size, and it has been 400 pixels wide since long before you uploaded anything.
Four Hundred Pixels, Whatever You Uploaded
Divi registers its own set of image sizes when the theme loads, and the one the Blog module reaches
for in grid layout is et-pb-post-main-image, which is 400 by 250. WordPress generates
that file on upload and that is the file the grid gets served. Your column is very often 500 or 600
pixels wide, so the browser stretches a 400 pixel image to fill it, and stretched is what soft
actually is. On a retina screen it is worse, because the browser wanted roughly double.
The cropping is the same setting seen from the other side. Those sizes are registered as hard crops, so a portrait photograph is cut to a 16:10 letterbox by the middle of the frame. That is why faces lose their foreheads in a blog grid and nowhere else on the site.
Switch the module to a block or fullwidth layout and it uses
et-pb-post-main-image-fullwidth at 1080 by 675 instead, which is why the same posts
suddenly look fine in a different layout and you start doubting your own eyes. These are the seven
Divi registers:
400x250 blog grid thumbnail
1080x675 blog fullwidth and block layouts
400x284 portfolio
510x382 portfolio module
1080x9999 portfolio single
400x516 gallery portrait
2880x1800 fullwidth large
One Filter Changes The Lot
The whole list is filterable before it is registered. Drop the key you do not want and add the size you do, keeping the same size name so everything that asks for it gets the bigger file:
add_filter( 'et_theme_image_sizes', function ( $sizes ) {
// Divi's blog grid thumbnail is 400x250 by default. Double it.
unset( $sizes['400x250'] );
$sizes['800x500'] = 'et-pb-post-main-image';
return $sizes;
} );
That goes in a child theme's functions.php, or in the Code Snippets plugin set to run
everywhere. It has to be in place before after_setup_theme, which is when Divi
registers the sizes, and both of those load early enough. It does not go in Theme Options
Integration: that box is for head and body markup, not PHP.
Then Regenerate, Or Nothing Happens
This is the step that gets skipped, and skipping it is why people decide the snippet does not work. Changing the registered size only changes what WordPress creates on future uploads. Every image already in your media library still has nothing on disk but the old 400 pixel file, so the grid carries on serving exactly what it served yesterday.
Run Regenerate Thumbnails once after adding the filter, or wp media regenerate if you
have WP-CLI. On a library of any size do it when the site is quiet, because it rewrites every
attachment you own.
If You Want The Crop Gone Instead
Sometimes the size is fine and the cropping is the problem. There is a separate filter for that:
add_filter( 'et_post_thumbnails_crop', '__return_false' );
Divi's sizes become soft resizes, so images keep their own proportions and nothing is cut. The tradeoff is real and you should decide it deliberately rather than discover it: a grid of mixed portrait and landscape photographs will no longer line up, because the thing that was making the rows even was the crop you just removed.
One Thing You Will Find In Older Advice
Search this problem and you will be handed et_pb_blog_image_width and
et_pb_blog_image_height. They still exist in Divi 5, and they are still called from the
Blog module, but they are kept for backwards compatibility and the dimensions they adjust are read
from the registered image size first. Change the registered size. Reaching for the legacy pair on
its own is how you end up with a snippet that appears to do nothing.
Why This One Is Worth Five Minutes
Nothing here is broken, which is precisely why it survives. No error appears, no plugin conflicts, the page loads fine, and the site just quietly looks a bit cheaper than the photography that was paid for. We check it on every Divi site we take over, usually before anything gets optimised or replaced, because it is five minutes of work and it changes how the whole blog reads.
Checked against Divi 5.13. The same two filters work on Divi 4.