Stand with Ukraine! How can you help?
Find out more

Guide for LLMs TXT Generator for Magento 2

Install, configure and improve AI visibility for most important pages

Magefan LLMs TXT Generator for Magento allows you to create a structured AI-readable llms.txt file for your store. This file helps AI crawlers understand your content properly and use it in AI search responses.

So, in this guide, you'll learn how to configure all available extension options and manage generation settings for your llms.txt file.

Installation

To install LLMs TXT Generator for Magento, navigate to your Magefan Account > Downloads > Install via Composer to get the Composer installation instructions. Or download the extension archive and copy the extracted files to your Magento root directory. 

Note: don't forget to run the static content deployment commands after uploading the archive.

General Settings

Navigate to Stores > Configuration > Magefan Extensions > LLMs.txt to configure the extension.

Company information

Define information about your company to appear in the LLMs.txt file.

  • Company Name — sets the main heading for the llms.txt file. It could be the company name or some custom title for the file.

e.g. set something like "Company name" or "Company name  LLMs Instructions".

  • Company Description — provides a short summary of your business and what is does. This helps AI understand your brand context and positioning.

e.g. Company name - is a global ecommerce retailer offering a wide range of consumer products across categories such as electronics, home goods, fashion, and lifestyle.

company information in llms txt magento

Page options

Define what pages to include in the llms.txt file, what attributes to use as page descriptions, and set limits for the number of pages.

You can add product, category, CMS, blog post, blog category, blog tag and blog author pages to the llms.txt file. All settings are the same across all page types.

  • Include in LLMs.txt — enables certain page types (e.g. products, categories, blog,etc.) in the file.

Note: the extension includes the first N pages (by ID) in the LLMs.txt file for each page type you enable.


If you want to add specific pages to the file, disable the Include in LLMs.txt option in the config. Instead, enable it for specific pages in the Generative Engine Optimisation section available on each page.

  • Use fields — defines what attributes to use as page description. Include more fields to provide more context about the page.
  • Max. Number To Include — defines the number of pages, per page type, that will be included in the llms.txt file.

product options for llms txt magento

Store URL

Specify whether to include the store base URL in LLMs.txt.

  • Include in LLMs.txt — adds your store base URL to the file. This helps AI systems identify your domain.

include store url in llms txt magento

Custom Content

Add custom content to the bottom of the llms.txt file

  • Custom Content — adds static content (in markdown formatting) to the end of the llms.txt file.

custom content in llms txt in magento

e.g. use this section to add instructions, recommendation logic, or content priorities AI systems should follow.

Generation Settings

Define how and when the llms.txt file is generated.

Note: once the generated llms.txt file is added to your Magento root via the /llms.txt path. Just add it to your domain address to view the file on frontend.

General

  • Enabled — enables or disables automatic generation of the llms.txt file. If disabled, no file is generated.
  • Frequency — defines how often the file is generated (e.g., daily).
  • Start Time — sets the time when generation starts.

Manual Generation

  • Generate LLMs.txt — allows you to generate the llms.txt file instantly without waiting for cron to run on schedule.
  • LLMs.txt File(s) — displays the generated llms.txt file URL for easy access.

Error handling

  • Error Email Recipient — specifies who receives error notifications.
  • Error Email Sender — defines the sender for error emails.
  • Error Email Template — selects the email template used for error notifications.

generate llm txt in magento

Generative Engine Optimisation

The extension also adds the page-level settings or llms.txt. Navigate to a page and find the Generative Engine Optimisation section.

  • Include in LLMs.txt — adds specific page to llms.txt file. Page-level settings override default settings. 

e.g. if you set a limit of 100 products in the config, and then enable the Include in LLMs.txt option for 50 specific products. The extension will add 50 products you've added and 50 random products added by the system logic.

Troubleshooting

Find the most common issues that might happen and their solutions.

LLMs.txt file not generated

If you can't find the file via the /llms.txt path, it means it wasn't generated. It usually happens when the extension is disabled or the cron generation is disabled.

Solution:

  1. Navigate to Stores > Configuration > Magefan Extensions > LLMs.txt and make sure the extension is enabled
  2. Then move to Generation Settings and check if it's Enabled.
  3. Check if the crons are configured and running using this CLI command:
php bin/magento cron:run

Missing products or categories

The extension adds pages to llms.txt by IDs — the first N number of pages you set as a limit. To add specific pages, you need to include a page in llms.txt on the page level in the Generative Engine Optimisation.

Solution:

  1. Make sure the page you want to include in the file is enabled in the Generative Engine Optimisation section.
  2. Increase the limit of a specific page type per file (Max. Number To Include) in the config section.

File too large

It usually happens if you add too many links or select too many fields for a page. Try to include no more than 100-200 links per file with one attribute as page description.

FAQs

How to add specific products to llms.txt in Magento?
collapsible icon
Navigate to Stores > Configuration > Magefan Extensions > LLMs TXT > Products Options and disable the Include in LLMs.txt.

Then go to Products and scroll down to the Generative Engine Optimization section of the products you wanted to include ine the llms.txt file.

Or select all products you want to include in the products grid and set Yes for them in the Include LLMs.txt option through mass attribute update.
Do I need to submit llms.txt file somewhere?
collapsible icon
No. The llms.txt file is located in your Magento root, the same as robots.txt. So AI crawlers can retrieve it the same way web crawlers find robots.txt.
Can I add all pages to llms txt in Magento?
collapsible icon
Yes. Magefan LLMs XT Generator allows you to add all pages to your llms.txt file. However, it is recommended to keep it short - up to 100-200 links, so it's easier to crawl and understand for AI.

Add only the most important pages you want AI systems to use in AI-generated answers.

We can't find posts matching the selection.
chevron-up Top