Template-Based Alt & Title Generation
Tokens — {{name}}, {{sku}}, {{store}}, {{category}} rendered per image in real time
Auto-generate SEO-optimized alt and title attributes for every product image on your storefront — from configurable templates with tokens ({{name}}, {{sku}}, {{store}}, {{category}}) and filters (truncate, title-case, strip, default, upp…
Key Features:
Additional Services
Built-in from day one. No add-ons, no upsell, no licence keys to renew.
Tokens — {{name}}, {{sku}}, {{store}}, {{category}} rendered per image in real time
Scope-respecting — every setting is configurable at default / website / store view level
Product detail page — main gallery image alt + caption + title
Preserves merchant-authored labels — if a product has a custom image label set in admin, that takes precedence
Runs inline — no external API calls, no DB writes, pure template rendering
MEQP compliant — follows Adobe's Magento Extension Quality Program standards
Panth Image SEO is a template-based alt and title generator for Magento 2 and Adobe Commerce that fills every product image with descriptive, scope-aware text. Replace blank alt="" attributes across the catalog with one merchant-controlled template that renders on every store view, every theme, and every storefront surface.
The module uses tokens ({{name}}, {{sku}}, {{store}}, {{category}}) and chainable filters (|truncate:N, |title, |upper, |lower, |strip, |default:'value') to optimize alt and title attributes per image in real time. Templates apply to PDP main galleries, fotorama and Hyva carousels, category grids, related, upsell, cross-sell, search results, and CMS product widgets — with multi-image position suffix support such as “Image 2 of 5”.
Image SEO is store-view scoped, so localized storefronts and multi-brand websites get the correct alt text per scope without code changes. Merchant-authored labels are preserved, generic Magento defaults like “main product photo” are replaced, and the module runs inline with zero external API calls or DB writes. Compatible with Hyva and Luma; a pluggable VisionAdapterInterface lets you wire OpenAI Vision or Claude Vision for AI-generated fallback alt text when a token resolves empty.
Image alt text is one of the most under-optimized and highest-leverage SEO signals for eCommerce:
alt="" or alt="Image" are invisible.Manually writing alt text for every product (or every image within every product) doesn't scale past a small catalog. Panth Image SEO lets one merchant-controlled template render correct, scope-aware alt text across the entire catalog in one pass — and refresh instantly when you change the template.
Image SEO ships a complete toolkit to optimize alt and title text behavior across every storefront surface:
VisionAdapterInterface for AI-generated fallback alt text.{{name}}, {{sku}}, {{store}}, {{category}} rendered per image in real time|truncate:N, |title, |lower, |upper, |strip, |default:'value' inside any token— Image 2 of 5)Image / main product photo / filename placeholders get upgraded automaticallyVisionAdapterInterface lets you swap in OpenAI Vision / Claude Vision for AI-generated fallback alt textEvery token is written as {{tokenName}} and can be combined with filters using |filterName:arg.
| Token | Value | Example Output |
|---|---|---|
{{name}} |
Product name | Push It Messenger Bag |
{{sku}} |
Product SKU | 24-WB04 |
{{store}} |
Current store view name | Luma Store View, Default Store View, English, Wholesale |
{{category}} |
Current category name (when resolvable) | Bags, Women's Tops |
Unknown tokens render as empty strings, so a template like Brand: {{brand}} / {{name}} safely falls back to Brand: / Push It Messenger Bag if the brand token isn't wired up yet. Trailing separators are auto-cleaned.
Filters are chained with | and run left-to-right.
| Filter | Syntax | Effect | Example |
|---|---|---|---|
truncate |
|truncate:N |
Clip to N characters, append … |
{{name|truncate:20}} → Push It Messenger B… |
title |
|title |
Title-case (first letter of each word uppercase) | {{name|lower|title}} → Push It Messenger Bag |
upper |
|upper |
UPPERCASE the value | {{sku|upper}} → 24-WB04 |
lower |
|lower |
lowercase the value | {{name|lower}} → push it messenger bag |
strip |
|strip |
Remove HTML tags and collapse whitespace | {{name|strip}} |
default |
|default:'Fallback' |
Use the argument when the value is empty | {{category|default:'Catalog'}} → Catalog |
Filters can be chained: {{name|lower|title|truncate:40}} is valid.
Alt: {{name}} - {{store}}
Title: {{name}}
Renders as:
Push It Messenger Bag - Luma Store View
Alt: {{name|truncate:80}} | Buy Online at {{store}}
Title: {{name}} — {{store}}
Alt: {{name}} in {{category|default:'our catalog'}}
Title: {{name}}
Alt: [{{sku|upper}}] {{name}} | {{store}}
Title: {{name|truncate:60}}
Alt: {{name}}
Title: {{name}}
Configure Alt Text Template at the store-view scope:
{{name}} | Premium Quality from {{store}}{{name}} | Qualité Premium - {{store}}[WHOLESALE] {{name}} - {{store}}The module hooks every surface where Magento renders an <img> tag for a product:
| Surface | Plugin | What gets injected |
|---|---|---|
| Category page tiles | ImageFactoryPlugin |
<img alt="…"> on every product card |
| Related / Upsell / Cross-sell | ImageFactoryPlugin |
Widget product image alt |
| Search results grid | ImageFactoryPlugin |
Thumbnail alt on every result |
| Product gallery (main image) | GalleryImageSeoPlugin |
caption field in gallery JSON |
| Product gallery (thumbnails) | GalleryImageSeoPlugin |
caption + position suffix (— Image 2 of 5) |
| Product page label | ImageAttributesPlugin + ProductImagePlugin |
Helper-level getLabel() return value |
| Admin image uploader | UploaderPlugin |
Default label on newly uploaded images |
| CMS widgets (New, Featured, …) | ImageFactoryPlugin |
Widget image alt |
| Panth_ProductGallery | Soft DI wire | When installed, injects ImageTemplateResolver into the custom gallery |
This breadth matters because Magento 2 has four different code paths that eventually render a product <img>:
Magento\Catalog\Block\Product\ImageFactory::create — used by category grids, widgets, related/upsell/cross-sellMagento\Catalog\Helper\Image::getLabel — used by some themes directlyMagento\Catalog\Block\Product\View\Gallery::getGalleryImagesJson — the product gallery JSONMissing any one of these leaves a gap where alt text stays blank or reverts to the Magento default. Panth Image SEO plugs all four, so the rendered HTML across your entire storefront is uniformly template-driven.
| Issue | Cause | Resolution |
|---|---|---|
| Alt text not changing on the storefront | FPC holding pre-install HTML | Run bin/magento cache:flush once after install |
| Category tile alt shows only product name, no store suffix | Old version (<1.0.1) without ImageFactoryPlugin |
Upgrade to v1.0.1+ via composer update mage2kishan/module-image-seo |
| Gallery main image caption shows "Image" | Old version (<1.0.1) with restricted placeholder detection | Upgrade to v1.0.1+ |
| Token renders as empty string | Unknown token name, or context variable not available | Check token spelling; see Token Reference |
| Different alt text across store views not respected | Setting edited at default scope | Switch scope dropdown to the specific store view before editing |
| Admin config page shows but options don't save | Admin user lacks permission on Panth_ImageSeo::config |
Grant the ACL resource under System → Permissions → User Roles |
| Gallery caption shows name only, no position suffix | Single-image product | Position suffix is only added for galleries with 2+ images (intentional) |
| Site slow after install | Missing bin/magento setup:di:compile in production mode |
Run DI compile + static content deploy in production mode |
| Requirement | Versions Supported |
|---|---|
| Magento Open Source | 2.4.4, 2.4.5, 2.4.6, 2.4.7, 2.4.8 |
| Adobe Commerce | 2.4.4, 2.4.5, 2.4.6, 2.4.7, 2.4.8 |
| Adobe Commerce Cloud | 2.4.4 — 2.4.8 |
| PHP | 8.1.x, 8.2.x, 8.3.x, 8.4.x |
| MySQL | 8.0+ |
| MariaDB | 10.4+ |
| Hyva Theme | 1.0+ (native support) |
| Luma Theme | Native support |
| Required Dependency | mage2kishan/module-core ^1.0 |
| Suggested Integration | mage2kishan/module-productgallery (auto-wires into the custom gallery) |
composer require mage2kishan/module-image-seo
bin/magento module:enable Panth_Core Panth_ImageSeo
bin/magento setup:upgrade
bin/magento setup:di:compile
bin/magento setup:static-content:deploy -f
bin/magento cache:flush
app/code/Panth/ImageSeo/ in your Magento installationPanth_Core is installed (required dependency)bin/magento module:enablebin/magento module:status Panth_ImageSeo
# Expected output: Module is enabled
Navigate to Admin → Stores → Configuration → Panth Extensions → Image SEO to configure the module.
| Setting | Default | Scope | Description |
|---|---|---|---|
| Enable Template-Based Image Alt/Title | Yes | Store View | Master toggle. When No, Magento's native alt/title behavior is used and all plugins are no-ops. |
| Alt Text Template | {{name}} - {{store}} |
Store View | Template rendered into every <img alt=""> attribute. Supports tokens and filters. |
| Title Text Template | {{name}} |
Store View | Template rendered into every <img title=""> attribute. Same token syntax; falls back to alt text when empty. |
| Apply to Gallery Images JSON | Yes | Store View | Also injects alt/title into the product gallery images JSON (used by fotorama and Hyva gallery widgets). |
All four settings are scope-aware. Configure a shorter alt template on a mobile-focused store view, a different brand suffix on a wholesale store, or different language alt text per localized store — Magento's scope hierarchy handles the rest.
Panth Image SEO is licensed under a proprietary license — see LICENSE.txt. One license per Magento installation.
| Module Category | SEO & Indexing |
|---|---|
| Best For | All Sizes |
No. Merchant-authored labels (anything other than empty, the product name, Image, main product photo, or the raw filename) are preserved. Only Magento's default placeholders get upgraded to template output.
Yes. The module injects into getGalleryImagesJson, which Hyva reads for its Alpine.js gallery. Category tile alt attributes go through ImageFactory, which Hyva's product/list.phtml also uses.
Yes. Luma's fotorama gallery reads from the same caption field, and Luma's category grid uses the same ImageFactory path.
Yes. mage2kishan/module-core is a required dependency and is pulled in automatically by Composer. Core provides the admin tab layout and common utilities.
Yes. The module ships with a VisionAdapterInterface and a NullVisionAdapter default. You can swap the preference in your di.xml to a custom adapter that calls OpenAI Vision, Claude Vision, or Google Cloud Vision for a vision-generated alt as the fallback when templates render empty. The vision adapter only fires when no template output was produced.
Yes. Every configuration setting respects Magento's standard scope hierarchy (default → website → store view). Configure a different alt template per store view and the plugins automatically honor it.
The module renders a separate title template so you can produce short, branded titles ({{name}}) while the alt attribute carries the SEO keyword copy ({{name}} | {{store}} | {{category}}).
Yes. Flip the master toggle to No in admin config and all plugins become no-ops instantly. The module's index data is not deleted, so re-enabling is instant.
No. The module is pure template rendering — no DB tables created, no writes. All state lives in Magento's cached scope config.
Set Apply to Gallery Images JSON to No. The master toggle stays on, so category tiles and widgets still get template alt; only the gallery JSON is left untouched.
Yes. When the module is enabled, the /contact URL is handled by Panth Advanced Contact Us and the stock Magento_Contact form is bypassed. Disable the module to revert to the native form — no data loss.
No. Google does not participate in IndexNow and has stated they maintain their own crawl schedule. For Google indexing, use a proper XML sitemap and Google Search Console. This module is specifically for the IndexNow ecosystem (Bing, Yandex, Seznam, Naver, Yep).
Yes. The module ships Hyva-native templates using Alpine.js and Tailwind. No jQuery required.
Minimally. The column loads order items for each visible row (typically 20-50 orders). For very large catalogs, you can disable thumbnails to reduce image loading.
Yes. The module ships dedicated Hyva templates built with Alpine.js and Tailwind CSS. Theme detection is automatic via Panth_Core.
No. Merchant-authored labels (anything other than empty, the product name, Image, main product photo, or the raw filename) are preserved. Only Magento's default placeholders get upgraded to template output.
Yes. Create as many sliders as you want in the admin and place each one via its own widget or layout block. Each slider maintains independent configuration and slides.
It enhances them. Magento's native meta fields still work — Panth Advanced SEO adds template-based defaults, tokens, hreflang groups, JSON-LD, SEO scoring, and dozens of other features Magento ships without.
Yes, guests can subscribe with their email address. You can optionally require login via admin config.
No. The head block is cacheable="true" so the full JSON-LD payload is baked into full-page cache. Providers only run on uncached renders; cached hits serve the pre-rendered <script> tag with zero PHP evaluation.
Talk to Kishan directly — written quote, scope and timeline within 24 hours. No sales call.
Image SEO — Alt & Title Generator for Magento 2