Does changing alt text in the Media Library update existing posts?

No. When you insert an image into a post, WordPress copies the alt text from the Media Library into that post's HTML at that moment. Editing the alt text in the Media Library afterwards changes the library record only. Images already placed in content keep whatever alt text they were inserted with.

Two places alt text lives

In the Media Library. Each attachment has an "Alternative Text" field. It is stored as a piece of metadata attached to the file's record.

In the post. An Image block saves a complete <img> tag, including its alt attribute, as part of the post content:

html
<img src="https://example.com/wp-content/uploads/2026/05/burr-grinder.jpg" alt="Hand burr grinder on a wooden counter" class="wp-image-482"/>

At the moment of insertion the editor fills that attribute from the Media Library value. After that the two are independent. Changing one does not change the other, in either direction: editing the alt text on an Image block in a post does not write back to the library.

When the post is displayed, core adds things like srcset, sizes and loading attributes to content images on the way out. It does not add or replace alt.

What does update automatically

Images that are not stored as HTML in content are built from the library record each time a page is rendered, so they always use the current alt text:

ImageUses current Media Library alt?
Featured image printed by the themeYes
Image block inserted in a post in the pastNo
Gallery block imagesNo, each is a saved image block
Classic editor images in old postsNo
Images output by template functions, such as product images and site logosYes
Image inserted todayYes, copied at insertion

One refinement for template-rendered images: if the library's alt field is empty, core prints an empty alt attribute. It does not fall back to the title or caption.

This split explains a common confusion. You fill in alt text for 200 library images, run an audit, and the featured images pass while the same images inside articles still fail.

Fixing images that are already in posts

You have three routes, from most precise to least effort.

1. Edit the image in the post. Click the Image block and type in the Alternative Text field in the sidebar. This is the only route that lets you write alt text suited to the context, which matters: the same photo may need different wording in a review and in a how-to.

2. Replace the image. Removing the block and inserting the image again copies the library's current alt text. Use it when the library value is right and there are only a few posts.

3. Fill missing alt attributes when the page is rendered. Hydrogen SEO's Add Missing ALT Attributes setting adds alt text to images in content that have none, as the page is output, using a format you choose. It does not write into your posts or the Media Library; see image SEO attributes. This covers a large back catalogue immediately, and you can still hand-write alt text on the images that matter most, since images with their own alt are left as they are.

For filling the library itself at scale, including generating descriptions, see bulk adding alt text. Remember that this alone fixes future insertions and featured images, not old content.

A database search-and-replace is sometimes suggested for old posts. It can work for a specific image, but matching the right <img> tags reliably across thousands of posts is error-prone. Take a backup and test on a copy if you try it.

Missing alt and empty alt are different things

When auditing, separate two cases:

  • No alt attribute at all. An accessibility failure. A screen reader may read the file name aloud.
  • alt="". A deliberate signal that the image is decorative and should be skipped. Correct for dividers, background flourishes and icons beside text that already says the same thing.

Only informative images need descriptive alt text. Google's image guidance asks for alt text that is useful and information-rich in the context of the page, and warns against stuffing it with keywords. Describe what the image shows in a short phrase, as you would to someone on the phone.

To see where a page stands, paste its HTML into the image alt checker, which lists every image with its alt state.

Habits that prevent the problem

  • Fill in alt text at upload, before inserting the image anywhere. Every later insertion then starts with a sensible value.
  • Adjust it per use when the context differs.
  • Check the block, not just the library, when reviewing a post before publishing.
  • Re-audit after bulk library edits so you know which images were actually affected.

Common questions

Why is my alt text missing on the page when it is set in the Media Library?

The image was inserted before the alt text was added, so the post's HTML has an empty or missing alt attribute. Edit the image block in the post.

Does editing alt text on an image block change the Media Library?

No. The change is saved in that post only, which lets one image carry different alt text in different places.

Do featured images use the Media Library alt text?

Yes. Themes print featured images from the library record at display time, so they always show the current alt text.

Does WordPress generate alt text from the file name?

No. Core leaves the alt field empty unless you fill it in. The file name is used for the attachment's title, not its alt text.