All skills
chromedevtools avatar

/debug-optimize-lcp

@50a16fa

Guides debugging and optimizing Largest Contentful Paint (LCP) using Chrome DevTools MCP tools. Use this skill whenever the user asks about LCP performance, slow page loads, Core Web Vitals optimization, or wants to understand why their page's main content takes too long to appear. Also use when the user mentions "largest contentful paint", "page load speed", "CWV", or wants to improve how fast their hero image or main content renders.

Use this Skill: https://skilld.dev/gh/chromedevtools/chrome-devtools-mcp/debug-optimize-lcp

This session only. Nothing lands on disk.

referenceselements-and-size.md

≈332 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Elements and Size for LCP

What Elements are Considered?

The types of elements considered for Largest Contentful Paint (LCP) are:

  • <img> elements: The first frame presentation time is used for animated content like GIFs.
  • <image> elements inside an <svg> element.
  • <video> elements: The poster image load time or first frame presentation time, whichever is earlier.
  • Background images: Elements with a background image loaded using url().
  • Block-level elements: Containing text nodes or other inline-level text element children.

Heuristics to Exclude Non-Contentful Elements

Chromium-based browsers use heuristics to exclude:

  • Elements with opacity of 0.
  • Elements that cover the full viewport (likely background).
  • Placeholder images or low-entropy images.

How is an Element's Size Determined?

  • Visible Area: Typically the size visible within the viewport. Extending outside, clipped, or overflow portions don't count.
  • Image Elements: Either the visible size or the intrinsic size, whichever is smaller.
  • Text Elements: The smallest rectangle containing all text nodes.
  • Exclusions: Margin, padding, and borders are not considered toward the size.
  • Containment: Every text node belongs to its closest block-level ancestor element.

Source: SKILL.md on GitHub

2 warnings16d5 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    This skill is a legitimate tool for web developers to diagnose and optimize 'Largest Contentful Paint' (LCP) performance. It uses standard Chrome DevTools instrumentation and safe JavaScript snippets to analyze web pages.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: MEDIUM · 1 issue

  • Runlayer7mo

    4/5 files flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at 50a16fa. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 1 hour ago.

Activeupdated last month

README badge

README badge for chromedevtools/chrome-devtools-mcp/debug-optimize-lcp