# Browser DevTools for Image Debugging: Complete Guide

> Diagnose image problems in DevTools: analyse loading order, inspect compression, and debug responsive images in Chrome, Firefox and Safari.

Canonical page: https://www.imageguide.dev/guides/browser-devtools-image-debugging/

Published: 2026-01-19. Updated: 2026-10-17.

Publisher: ImageGuide, published by Sirv. [Editorial method](https://www.imageguide.dev/about/#how-we-write).

## Quick answer

To debug image performance, inspect the browser's Network panel for the requested URL, transferred bytes, and request timing. Compare the decoded dimensions with the displayed size and check which element is LCP. Use a throttled mobile test to identify late discovery, oversized downloads, and layout shifts.

Reference for this answer: [Google guidance on image LCP](https://web.dev/articles/optimize-lcp).

## Chrome DevTools

### Network Panel: Image Analysis

Open DevTools (`F12` or `Cmd+Opt+I`) → Network tab → Filter by "Img"

#### Key Columns to Enable

Right-click column headers to show:
- **Size**: Transferred vs actual size
- **Time**: Total load time
- **Waterfall**: Visual loading timeline

#### Analyzing Image Requests

| Metric | What to Check | Target |
|--------|--------------|--------|
| Size | Transferred bytes | Under 200KB typical |
| Time | TTFB + download | Under 500ms |
| Status | 200 OK, not 304 | Fresh or properly cached |
| Protocol | h2 or h3 | HTTP/2+ for multiplexing |

#### Checking Compression

Click an image → Headers tab:

```
Content-Type: image/webp
Content-Length: 45678
Content-Encoding: (should be empty for images)
```

### Elements Panel: Image Inspection

Inspect an image element to see:

#### Computed Size vs Natural Size

```
Rendered size: 400 × 300
Intrinsic size: 1200 × 900
Current source: image.webp
```

If intrinsic size >> rendered size, the image is oversized.

#### Responsive Image Debugging

For `srcset` images, DevTools shows which source is selected:

```html
<img srcset="small.jpg 400w, medium.jpg 800w, large.jpg 1200w"
     sizes="(max-width: 600px) 100vw, 50vw"
     src="medium.jpg">
```

Hover over to see "Current source" in Elements panel.

### Performance Panel: LCP Analysis

1. Record a page load
2. Look for "LCP" marker in the timeline
3. Click to see which element triggered LCP

Common LCP image issues:
- Late discovery (not in initial HTML)
- Large file size
- Missing `fetchpriority="high"`
- Lazy loading (shouldn't lazy load LCP)

### Lighthouse: Automated Audits

Run Lighthouse → Performance

Image-specific audits:
- **Properly size images**: Oversized images
- **Serve images in next-gen formats**: Missing WebP/AVIF
- **Efficiently encode images**: Uncompressed images
- **Defer offscreen images**: Missing lazy loading
- **Image elements have explicit width and height**: CLS issues

### Coverage Tab: Unused Images

DevTools → More tools → Coverage

1. Click record
2. Load page
3. Check for image URLs with low coverage

Unused bytes in CSS background images or preloaded but unused images appear here.

## Firefox DevTools

### Network Panel Differences

Firefox provides additional image-specific info:

#### Image Tab

Click an image request → Response tab → Image tab

Shows:
- Preview
- Dimensions
- MIME type
- File size
- Decoded size (memory usage)

#### Blocking Requests

Right-click → Block URL pattern

Test how your page handles:
- Blocked images (image-off mode)
- Slow image loading

### Responsive Design Mode

`Ctrl+Shift+M` or `Cmd+Opt+M`

Test srcset behavior at different viewports:
1. Enable Responsive Design Mode
2. Change viewport width
3. Watch Network panel for different image sources

### Accessibility Inspector

Inspecting images for accessibility:

1. Open Accessibility tab
2. Click image element
3. Check:
   - Name (from alt text)
   - Role (should be "img" or "graphics-document")
   - States (focusable, etc.)

## Safari DevTools

### Network Tab

Safari shows unique info:

- **Priority**: How browser prioritized the request
- **Connection ID**: See HTTP/2 multiplexing

### Graphics Tab

Unique to Safari:

1. Open Web Inspector
2. Graphics tab
3. See all images with:
   - Memory usage
   - Dimensions
   - Layers (for composited images)

### Canvas Recording

For canvas-based images or image manipulation:

1. Graphics tab → Canvases
2. Record canvas calls
3. Analyze image drawing operations

## Common Debugging Scenarios

### Scenario 1: Images Loading Slowly

**Diagnosis steps:**

1. Network panel → Sort by Time
2. Check TTFB (server response time)
3. Check Content Download time
4. Analyze waterfall for blocking

**Common causes:**
- No CDN (high TTFB)
- Large file size
- Too many images loading at once
- Not using HTTP/2

**Solution:**

```html
<!-- Use CDN like Sirv -->
<img src="https://your-site.sirv.com/image.jpg?format=optimal">
```

### Scenario 2: Wrong Image Size Served

**Diagnosis:**

Elements panel → Inspect image → Check intrinsic vs rendered size

**Problem:** 2000px image displayed at 400px

**Solution:**

```html
<img
  src="image-400.jpg"
  srcset="
    image-400.jpg 400w,
    image-800.jpg 800w,
    image-1200.jpg 1200w
  "
  sizes="(max-width: 600px) 100vw, 400px"
>
```

### Scenario 3: LCP Image Too Slow

**Diagnosis:**

Performance panel → Record → Find LCP marker

**Common issues:**
1. Image lazy loaded (remove `loading="lazy"`)
2. Late discovery (add `<link rel="preload">`)
3. Low priority (add `fetchpriority="high"`)

**Solution:**

```html
<link rel="preload" as="image" href="hero.webp" fetchpriority="high">

<img
  src="hero.webp"
  alt="Hero image"
  fetchpriority="high"
>
```

### Scenario 4: Layout Shift from Images

**Diagnosis:**

Performance panel → Look for "Layout Shift" events

Correlate with image loading in waterfall.

**Solution:**

```html
<!-- Always include dimensions -->
<img
  src="product.jpg"
  alt="Product"
  width="400"
  height="300"
>

<!-- Or use aspect-ratio -->
<style>
  img { aspect-ratio: 4/3; width: 100%; height: auto; }
</style>
```

### Scenario 5: Images Not Using Modern Formats

**Diagnosis:**

Network panel → Check Content-Type header

If all images are `image/jpeg` or `image/png`, modern formats aren't being served.

**Solution with Sirv:**

```html
<!-- Sirv serves optimal format automatically -->
<img src="https://your-site.sirv.com/photo.jpg?format=optimal">
```

## Useful DevTools Commands

### Console Commands

```javascript
// List all images and their sizes
document.querySelectorAll('img').forEach(img => {
  console.log({
    src: img.src,
    rendered: `${img.width}×${img.height}`,
    natural: `${img.naturalWidth}×${img.naturalHeight}`,
    oversized: img.naturalWidth > img.width * 2
  });
});

// Find lazy-loaded images above the fold
const viewportHeight = window.innerHeight;
document.querySelectorAll('img[loading="lazy"]').forEach(img => {
  const rect = img.getBoundingClientRect();
  if (rect.top < viewportHeight) {
    console.warn('Lazy image above fold:', img.src);
  }
});

// Check for missing alt text
document.querySelectorAll('img:not([alt])').forEach(img => {
  console.error('Missing alt:', img.src);
});
```

### Network Panel Filters

```
# Only JPEG images
mime-type:image/jpeg

# Images over 100KB
larger-than:100000

# Images from specific domain
domain:cdn.example.com

# Specific status codes
status-code:200
```

## Performance Monitoring

### Real User Monitoring (RUM)

```javascript
// Track LCP image
new PerformanceObserver((list) => {
  const entries = list.getEntries();
  const lcpEntry = entries[entries.length - 1];

  if (lcpEntry.element?.tagName === 'IMG') {
    console.log('LCP Image:', {
      src: lcpEntry.element.src,
      loadTime: lcpEntry.loadTime,
      renderTime: lcpEntry.renderTime,
      size: lcpEntry.size
    });
  }
}).observe({ type: 'largest-contentful-paint', buffered: true });
```

### Image Loading Performance

```javascript
// Track all image load times
const imageMetrics = [];

document.querySelectorAll('img').forEach(img => {
  const start = performance.now();

  img.addEventListener('load', () => {
    imageMetrics.push({
      src: img.src,
      loadTime: performance.now() - start,
      size: `${img.naturalWidth}×${img.naturalHeight}`
    });
  });
});

// Report after page load
window.addEventListener('load', () => {
  console.table(imageMetrics);
});
```

## Browser Extensions

### Helpful Extensions

| Extension | Purpose |
|-----------|---------|
| Web Vitals | Real-time CWV monitoring |
| Lighthouse CI | Automated audits |
| ImageOptim | Analyze compression |
| PerfectPixel | Compare designs |

## Conclusion

Effective image debugging requires:

1. **Network panel** - Analyze loading, size, format
2. **Elements panel** - Check rendered vs intrinsic size
3. **Performance panel** - Identify LCP issues
4. **Lighthouse** - Automated optimization audits
5. **Console** - Custom diagnostic scripts

Use [Sirv](https://my.sirv.com/#/signup) to automatically optimize images and eliminate many common issues before they require debugging.

## Sources

- [Network features, Chrome DevTools](https://developer.chrome.com/docs/devtools/network)
- [Firefox DevTools user documentation, MDN](https://firefox-source-docs.mozilla.org/devtools-user/)
