To add alt text to images in WordPress, select an image in the block editor and enter a description in the Alternative text field in its block settings. Save or update the post, then check the published page. If you plan to reuse the image, you can also set its alt text in the Media Library. An existing post may still need its own edit because the two fields serve different purposes.
Decide what the image needs to communicate
Alt text gives someone who cannot see an image the information it contributes to the page. For an informative image, describe its purpose in the surrounding content, not every visible detail. The W3C guidance on images explains how the right approach depends on the image’s role.
On a bakery menu, a product photo might need “Sourdough loaf with a dark crust and flour-dusted top.” In instructions about checkout settings, a screenshot might need “Shipping options panel with local pickup enabled.” These are examples, not descriptions to copy without checking the actual images. Avoid strings of search terms and introductory words such as “image of” when they add nothing.
Leave the field empty when the image adds no information, such as a decorative flourish beside an already clear heading. Empty means no text in the field, not the words “decorative image.” If an image is the only content of a link, its accessible name needs to convey the link’s destination or action. Use the W3C alt text decision tree when the image’s role is unclear.
Add alt text in the WordPress Image block
Use the block editor when the description should fit a particular post or page. You need permission to edit that content, and the image must be in a core Image block. WordPress’s Image block documentation identifies the Alternative text field in the block settings.
- Open the post or page in the WordPress editor.
- Select the image. If the settings sidebar is hidden, open it and view the settings for the selected block.
- Find Alternative text. Enter a description that fits this use of the image, or leave the field empty if the image is purely decorative here.
- Save or update the post or page, then open its preview or published version.
The description entered in an Image block applies to that image instance. This is useful when the same photo has different jobs on different pages. A storefront photo on an accessibility page might need “Entrance with a step-free doorway,” while a post about seasonal decorations might describe the window display instead.
When you insert an image from the Media Library, its existing attachment alt text may provide a starting value in the new block. Check that value before publishing. Changing one block’s field does not revise every other use of the file.
Add alt text in the Media Library
Use the Media Library to maintain the image attachment’s alt text for future insertions. In WordPress, open Media → Library, select the image, and find its Alternative Text field in the attachment details. Enter a concise description and save the change if that screen asks you to. WordPress covers attachment editing in its Edit Media guide.
Attachment alt text and text saved in an existing Image block are not interchangeable. An Image block can store its own value, so editing the Media Library field does not reliably update images already placed in posts or pages. Review those uses individually when correcting older descriptions. A gallery, theme, or plugin may also use attachment data differently.
For example, “Ceramic mug with blue glaze” might be a useful attachment description for later insertions. If an existing post uses that photo to show where the maker’s stamp appears, edit that post’s Image block with a description relevant to the stamp. The Media Library cannot supply every page’s context.
Check the rendered result
After saving, open the page preview or published page. Confirm that the intended image appears and that its description makes sense beside the heading, caption, and body text. If nearby text already conveys everything the image adds, consider whether the image is decorative in that context.
For a direct check, right-click the image on the rendered page and inspect its HTML with your browser’s developer tools. Find the image’s alt attribute. An informative image should contain the intended text, such as alt="Entrance with a step-free doorway". A decorative image should generally have alt="", which is different from an image missing the attribute altogether.
Check linked images separately. For example, a linked logo should tell a reader where the link goes rather than merely describe its colors; the W3C’s guidance for functional images explains this use. If a page builder, product gallery, or other plugin renders the image, its controls may differ from the core Image block. Find the relevant field in that tool and inspect the published output instead of assuming a Media Library edit carried through.
Review older images systematically
Start with important pages and recent posts. Open each page, identify images that convey information, and compare their Image block fields with the rendered page. An empty Media Library field alone does not prove every use of an image lacks useful alt text. Likewise, a filled attachment field does not prove an existing block or plugin displays it.
Keep a short review list with the page URL, image, proposed description, and whether the image is decorative. Ask someone familiar with the product, place, or process pictured to confirm details you cannot establish from the image. For screenshots, describe the screen that is actually shown; if the screenshot is replaced, review its alt text again.
Use DexWP to prepare a review
Dex can read and edit supported posts and pages on a connected WordPress site. You can ask it to help identify images that may need attention and propose descriptions, then review those suggestions against each image and its page context before editing.
Suggested Dex request: “Review my recent WordPress posts and pages for images that may be missing useful alt text. List each page and image you can assess, suggest context-specific descriptions, and flag images that may be decorative. Show me the proposed changes before editing.”
Check what Dex can access on your connected site. Images rendered by a builder, gallery, or plugin may still need manual review. For a broader maintenance workflow, see how to turn WordPress tasks into a conversation with Dex. You can connect your WordPress site with DexWP if you want to try this approach.
Common questions
Will changing Media Library alt text fix images in old posts?
Do not assume it will. Existing Image blocks can have alt text saved for that particular use, and other image tools may handle attachment data differently. Edit the relevant post or page, then inspect the published image’s alt attribute to confirm the change.
Should every WordPress image have written alt text?
No. Give informative images text that conveys their purpose in context. Leave purely decorative images with an empty alt attribute. If you are unsure, read the surrounding page without the image and ask what information a reader would miss.
