images warning images/alt-text

Image Alt Text SEO Rule

Validate that all images have descriptive, non-generic alt text for SEO and accessibility

What This Rule Checks

Checks every image for alt attribute presence, empty alt text without decorative markers, length over 125 characters, generic text patterns (image, photo, screenshot), filename-style alt text, and keyword stuffing.

Why It Matters for SEO & GEO

Alt text helps search engines understand image content and is essential for accessibility. Missing or poor alt text means lost image search traffic and WCAG compliance failures.

How to Fix

Add descriptive alt text to every content image. Keep it under 125 characters. Avoid generic words like 'image' or 'photo'. Use role='presentation' for decorative images with empty alt.

Examples

Bad

<img src="hero.jpg">

Good

<img src="hero.jpg" alt="Developer using VibeLinter CLI to audit website SEO">

How VibeLinter Checks Image Alt Text

VibeLinter’s images/alt-text rule performs these checks on every image:

  1. Missing alt attribute — Warns when the alt attribute is completely absent from an <img> tag
  2. Empty alt validation — For empty alt text, checks if the image is marked as decorative (role="presentation" or aria-hidden="true"); issues info if not
  3. Length check — Warns when alt text exceeds 125 characters (configurable via maxLength)
  4. Generic text detection — Catches generic patterns: “image”, “photo”, “picture”, “screenshot”, “placeholder”, “untitled”, or numbered names like “img1”
  5. Filename detection — Flags alt text that appears to be a filename (ending in .jpg, .png, .webp, etc.)
  6. Keyword stuffing — Warns when alt text has more than 10 words with less than 70% unique words

Configuration

// vibelinter.config.cjs
module.exports = {
  rules: {
    'images/alt-text': {
      enabled: true,
      severity: 'warning',
      maxLength: 125,
      checkDecorative: true
    }
  }
}

SEO Impact

Proper image alt text affects:

  • Image search rankings — Alt text is the primary signal for Google Images ranking
  • Contextual relevance — Alt text helps search engines understand how images relate to surrounding content
  • Accessibility compliance — Required for WCAG 2.1 Level A compliance
  • GEO (Generative Engine Optimization) — AI models use alt text to understand visual content; descriptive alt text helps AI accurately describe and reference your images in generated responses

Related SEO Topics

image alt text SEOalt attribute optimizationimage accessibility checkeralt text best practicesgeneric alt text detectionkeyword stuffing alt text

Related Rules

References