Support Log in
All Features: WordPress SEO Plugin with AI Tools

WordPress Image SEO: Auto Alt Text and Sitemap Images

Image search can send visitors to your site. Rank Forge adds alt text from the file name when you upload an image that has none, and lists the featured image of each post in the XML sitemap.


Why image SEO matters

People who search visually (product images, recipe photos, “how-to” illustrations, stock imagery, etc.) use Google Images. Pages with well-optimized images can appear in both web search and image search.

Image SEO has three core components:

  1. Alt text — descriptive text for each image (used by screen readers and search engines)
  2. Image tags in the sitemap — XML sitemap annotations that tell Google where the featured image of a post is
  3. Image file optimization — file names, sizes, and formats that signal quality

Rank Forge handles the first two automatically. The third is covered by general WordPress image optimization plugins (not Rank Forge’s scope, but worth doing).


Auto alt text from filenames

When you upload an image to the WordPress media library and it has no alt text, Rank Forge writes one from the file name and saves it as the alt text of the image. A name is turned into words like this:

  • my-awesome-photo-2024.jpg → “My Awesome Photo 2024”
  • dental-clinic-downtown-chicago.png → “Dental Clinic Downtown Chicago”
  • IMG_4523.jpg → “Img 4523”

Dashes, underscores and dots become spaces, every word starts with a capital letter, and a size such as 300×200 or a word such as scaled, edited, copy or final at the end of the name is dropped. When the image is attached to a post, a dash and the title of that post follow the text. You can change the alt text in the Media Library.

Alt text is made from the filename only. For images with generic filenames (IMG_XXXX, screenshot1.png, image.jpg) the result is not descriptive, so write the alt text for those images yourself in the Media Library. Rank Forge does not look at the image itself.


Reminder in the Media Library

When you open an image in the Media Library that still has no alt text, its details show an orange note that starts “This image has no alt text.” Rank Forge does not work through the images that are already in your library, and the free plugin has no bulk alt-text screen. With the Pro add-on, Site Audit lists the posts whose content has images without alt text.


Featured image in the sitemap

Rank Forge’s XML sitemap lists the featured image of each post in the entry of that post:

<url>
  <loc>https://example.com/blog/wordpress-seo-guide/</loc>
  <image:image>
    <image:loc>https://example.com/wp-content/uploads/2026/04/seo-score.jpg</image:loc>
  </image:image>
</url>

The entry holds the featured image of a post, with its address in <image:loc>. The other images in the text of a post are not added, and the entry has no image title or caption.


Alt text best practices

Good alt text:

Do

  • Describe the image content“A laptop showing the Rank Forge dashboard”
  • Include your focus keyword naturally if relevant
  • Keep it under 125 characters (screen reader limit)
  • Use sentence case, not title case

Don’t

  • Keyword stuff“SEO plugin, best SEO plugin, WordPress SEO, AI SEO, top SEO plugin”
  • Use “image of” or “picture of”redundant for screen readers
  • Leave alt empty on content imagesit hurts accessibility and SEO
  • Copy the same alt across multiple images

Filename SEO

When you upload an image, Rank Forge cleans its file name before WordPress saves the file:

  • Letters are made lowercase and accents are removed
  • Spaces and underscores become hyphens, other characters that are not letters or digits become hyphens, and repeated hyphens are merged
  • The file extension is made lowercase

For example, My Photo (1).JPG is saved as my-photo-1.jpg and IMG_4523.jpg as img-4523.jpg. This applies to images that you upload; a file name written entirely in a non-Latin script is left as it is. Rank Forge does not check whether a file name describes the image, and it does not rename files that are already in the Media Library.


When it runs

Rank Forge does this work when you upload an image: it cleans the file name and writes the alt text. It saves the alt text in the standard WordPress field of the image, _wp_attachment_image_alt in the wp_postmeta table, like any other WordPress image attribute.


Ready to fix your image SEO?

See pricing →

Image SEO is included in every plan — free and paid.

Forge AI Assistant Online

Hi! I'm the Rank Forge AI assistant. Ask me anything about the plugin — setup, features, troubleshooting, or development.

Just now
Powered by Forge AI · Browse docs