Description
Images without alt text are bad for people who use screen readers and a missed chance for image search. DevLab Image Alt fills in the gaps automatically, at the moment the page is displayed. Your media library and your posts are not edited, so there is nothing to undo.
What it does
- Looks for images that have an empty or missing
altattribute and fills it in from the source you choose: the attachment title (default), the caption, the description, or the file name cleaned up (extension, size and duplicate-upload suffixes removed, hyphens and underscores turned into spaces, first letter capitalised when the name has no capital letters). - Works on images printed by WordPress from the media library, such as featured images and most theme templates.
- Works on images inside your post and page content, when the image is a file from your media library.
- If the field you chose is empty for an image, it falls back to the cleaned-up file name. Long text is shortened to about 125 characters.
- It skips text that would say nothing, such as camera, phone and screenshot names (
IMG_4032,IMG-20261024-WA0012,Screenshot 2026-10-24 at 3.20.11 PM,Captura de Tela 2026-10-24 às 15.20.11), hash file names or names with no real word, and leaves those images without alt text instead of adding noise. - It respects images marked as decorative (
role="presentation"oraria-hidden="true") and leaves their empty alt as it is.
What it does not do
- It never changes alt text that already has content.
- It does not edit the media library or your posts, and it does not run bulk jobs. Switch the plugin off (and clear your page cache) and your pages are exactly as they were.
- It does not touch images that come from other websites.
- Apart from the explicit markers above, it cannot tell a purely decorative image (where an empty alt is intentional) from a forgotten one, so it fills both. Alt text written by a person is always better than an automatic one.
Light and quiet
The plugin only filters output. It never writes alt text to your database: it stores one small settings option and, per user, a flag that remembers a dismissed notice. It does not touch .htaccess, does not store any cache, does not crawl your site and loads no file on your public pages. Only the <img> tags that need an alt are edited; the rest of your HTML is left exactly as it was.
For developers
Use the devlab_alt_text filter to change the text before it is used, or return an empty string to leave an image without alt text:
add_filter( 'devlab_alt_text', function ( $text, $attachment_id, $source ) { return $text; }, 10, 3 );
Privacy
This plugin collects no data, sends no data to anyone, contacts no external service and needs no account or API key. It does not set cookies. It does not provide legal advice and does not guarantee that your site meets any accessibility standard or law; it fills in one missing attribute.
About DevLab
DevLab builds plugins and themes for WordPress. The plugin adds a DevLab menu with its settings screen. That screen has a small box with a link to the DevLab Store (devlab.ia.br/store) and one dismissible notice. Nothing promotional is added anywhere else in your dashboard or to your public pages (the only change there is the missing alt attribute), and the plugin never adds a credit link to your site.
Screenshots


Installation
- Upload the
devlab-image-altfolder to the/wp-content/plugins/directory, or install the plugin from the Plugins screen in WordPress. - Activate the plugin through the Plugins screen. Missing alt text is now filled in, using the attachment title.
- To change the source or where it applies, go to DevLab > Image Alt, adjust the options and click Save Changes.
FAQ
-
Where do I find the settings?
-
In the WordPress dashboard, under DevLab > Image Alt. There is also a Settings link on the Plugins screen.
-
Does it change my media library or my posts?
-
No. The alt text is added only in the HTML that visitors receive. Nothing is written to your media library or your posts; the plugin only stores its own settings option and a per-user flag for its dismissed notice.
-
Will it overwrite alt text I already wrote?
-
No. Only empty or missing alt attributes are filled in.
-
An image is decorative and should have an empty alt.
-
An empty alt is the right choice for purely decorative images. The plugin leaves alone images marked with
role="presentation",role="none"oraria-hidden="true". For any other image with an empty alt it cannot tell whether the emptiness was intentional, so it fills it. If you need an exception, use thedevlab_alt_textfilter to return an empty string for that attachment. -
Why is the alt text of some image just its file name?
-
When the source you chose (for example the caption) is empty for an image, the plugin uses the cleaned-up file name instead. Titles are filled by WordPress from the file name when you upload, so the default source gives similar results. If the file name says nothing (
IMG_4032), no alt text is added. For the best results, write real alt text in the media library. -
Why did nothing change on my site?
-
If you use a page cache or a performance plugin, clear its cache after you save the settings. Also check that the image is a file from your media library: images from other websites are not changed.
-
Does it work with page builders and the block editor?
-
It works on the HTML that WordPress prints for post content and on images printed with the standard WordPress image functions. A builder that prints its own
<img>tags outside of the post content, or that builds images without WordPress functions, is outside of what the plugin can see. -
Does it make my site accessible or compliant with any law?
-
No. It fills in one missing attribute. Please check the accessibility rules that apply to you for everything else your site does.
-
What happens when I delete the plugin?
-
The plugin’s option and the “notice dismissed” flag are removed. Your media library, posts and other settings are not touched, because the plugin never changed them.
Reviews
There are no reviews for this plugin.
Contributors & Developers
“DevLab Image Alt” is open source software. The following people have contributed to this plugin.
ContributorsTranslate “DevLab Image Alt” into your language.
Interested in development?
Browse the code, check out the SVN repository, or subscribe to the development log by RSS.
Changelog
0.1.1
- First public release.
