I’m trying to improve the Largest Contentful Paint (LCP) on one of my pages. The main LCP element is an image that is loaded dynamically via PHP.
I have already compressed the image and the final size is just 22KB, but the LCP is still reported as 2.6 seconds in PageSpeed Insights.
Here is the relevant CSS:
.ArtistImageD001 {
display: block;
width: 100%;
height: 100%;
object-fit: cover;
border-radius: 0 20px 20px 0;
}
And here’s the image element in my PHP/HTML:
<img alt="<?php echo $artistDetail->first_name . ' ' . $artistDetail->last_name; ?>"
src="<?php echo base_url(); ?>apppanel/assets/artistimage/<?php echo $imageUrlFinalShow; ?>"
class="ArtistImageD001" />
Despite the small image size and optimizations, LCP is still high.
What I’ve tried so far:
- Compressed the image to 22KB.
- Made sure object-fit: cover doesn’t cause content shifts.
- Verified that the image is not lazy-loaded.
Questions I have:
- What else can I do to improve LCP in this case?
- Is there any PHP or HTML-related optimization I can make since the
image is dynamic? - Should I use
<link rel="preload">or something else for the image?

