{"id":3558,"date":"2024-08-28T11:10:14","date_gmt":"2024-08-28T11:10:14","guid":{"rendered":"https:\/\/meetanshi.com\/blog\/how-to-attach-files-to-products-in-magento-2\/"},"modified":"2025-06-16T12:11:50","modified_gmt":"2025-06-16T06:41:50","slug":"how-to-attach-files-to-products-in-magento-2","status":"publish","type":"post","link":"https:\/\/meetanshi.com\/blog\/how-to-attach-files-to-products-in-magento-2\/","title":{"rendered":"How to Attach Files to Products in Magento 2 In Easy Steps"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">A great customer experience is the key to the success of your business, especially when customer expectations are soaring in an evolving market.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Unlike in the early days of e-commerce, now, customers might expect to know certain things about a product before buying it. For example, they might want to watch a demo to see how it works. Or a license to be sure about its authenticity.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Providing your customers with helpful information and helping them make informed decisions is an effective way of winning your customer\u2019s trust.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In this guide, you\u2019ll learn how to attach files to products in Magento 2.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What is The Product Attachment For Magento 2?<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Product attachment for Magento 2 is a way to attach files, whether PDFs, images, videos, etc., to products listed on your Magento 2 store.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The purpose behind adding attachments is to provide customers with additional, crucial information about products. For example, you can <a href=\"https:\/\/meetanshi.com\/blog\/attach-pdf-to-product-in-magento-2\/\" data-type=\"link\" data-id=\"https:\/\/meetanshi.com\/blog\/attach-pdf-to-product-in-magento-2\/\">add a PDF to a product in Magento 2<\/a> to showcase the step-by-step working functionality of your product.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/product-attachement-seen-frontend.png\" alt=\"product attachment frontend\" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">Product attachments in Magento 2 help you improve customer experience, resulting in a better chance of selling more products.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">However, Magento 2 doesn\u2019t provide built-in functionality to add attachments. This leaves you with two options \u2013 either you custom-build the attachment functionality or rely on third-party extensions. If you\u2019re not tech-savvy or don\u2019t want to engage in custom coding, the second option is best for you.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In this guide, you will learn how to attach files to products in Magento 2 without coding using Meetanshi\u2019s&nbsp;<a href=\"https:\/\/meetanshi.com\/magento-2-product-attachments.html\" target=\"_blank\" rel=\"noreferrer noopener\">Magento 2 Product Attachments<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to Attach Files to Products in Magento 2?<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"install\">1. Install the Magento 2 Product Attachments Extension<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Get the Meetanshi&nbsp;<a href=\"https:\/\/meetanshi.com\/magento-2-product-attachments.html\">Magento 2 Product Attachments<\/a>&nbsp;extension and download the zip folder.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/magento-2-product-attachments-extension-by-meetanshi.png\" alt=\"Magento 2 product attachment extension by Meetanshi\" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">Next, via FTP, upload the extension to the root of your Magento 2 directory. Lastly, run the following commands in your SSH step by step:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>php bin\/magento setup:upgrade<\/code><\/li>\n\n\n\n<li><code>php bin\/magento setup:static-content:deploy (for Magento version 2.0.x to 2.1.x)<\/code><\/li>\n\n\n\n<li><code>php bin\/magento setup:static-content:deploy \u2013f (for Magento version 2.2.x &amp; above)<\/code><\/li>\n\n\n\n<li><code>php bin\/magento cache:flush<\/code><\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"configure\">2. Configure the Extension<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Once you have installed the extension, it\u2019s time to configure it. For that, log in to Magento 2, and follow the following path:&nbsp;<strong>Stores &gt; Configuration &gt; Product Attachments.<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">There, you will find different configuration tabs. Adjust the settings as per below:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Product Attachments:&nbsp;<\/strong>Select&nbsp;<strong>Enable<\/strong>&nbsp;from the dropdown.<\/li>\n\n\n\n<li><strong>Product Attachments Tab Title:<\/strong>&nbsp;Enter your title for the attachment tab on your product page.<\/li>\n\n\n\n<li><strong>Product Attachments Heading:<\/strong>&nbsp;Add a heading for the attachments.<\/li>\n\n\n\n<li><strong>Display File Size:<\/strong>&nbsp;Select&nbsp;<strong>YES<\/strong>&nbsp;from the dropdown to display file size in the frontend. You can select&nbsp;<strong>NO<\/strong>&nbsp;if you don\u2019t want to show the file size.<\/li>\n\n\n\n<li><strong>Display Count of Downloads:<\/strong>&nbsp;Select&nbsp;<strong>YES<\/strong>&nbsp;from the dropdown to display the number of downloads in the frontend. If you choose not to show it, select&nbsp;<strong>NO<\/strong>.<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/product-attachment-configuration-general-settings-.png\" alt=\"Product attachment general settings\" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<h3 class=\"wp-block-heading\" id=\"CMS\">3. Configure the CMS Page Settings<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">After configuring the extension, the next step would be enabling product attachments to CMS pages. For that, follow the following instructions on CMS Page Settings<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>In the&nbsp;<strong>Enable CMS Attachments<\/strong>&nbsp;tab, select YES from the dropdown.<\/li>\n\n\n\n<li>In the&nbsp;<strong>CMS Page Attachments Heading<\/strong>, enter the heading for product attachments that would be shown on CMS pages.<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/configure-cms-page-settings-for-product-attachments.png\" alt=\"Configure cms page settings for product attachments\" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<h3 class=\"wp-block-heading\" id=\"categories\">4. Create Attachment Categories<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The purpose of creating attachment categories is to manage similar attachments properly in a single category.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For that, follow the following path in the extension:&nbsp;<strong>Catalog &gt; Product Attachments &gt; Manage Attachment Categories<\/strong><strong><em>.&nbsp;<\/em><\/strong>To create a new attachment category, you have to fill three fields below<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Name:<\/strong>&nbsp;Give an appropriate name to the category<\/li>\n\n\n\n<li><strong>Description:<\/strong>&nbsp;Add a description for the category<\/li>\n\n\n\n<li><strong>Is Active:<\/strong>&nbsp;Select&nbsp;<strong>Yes<\/strong>&nbsp;from the dropdown to enable the category<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/create-product-attachment-categories.png\" alt=\"Create product attachment categories\" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">In the&nbsp;<strong>Manage Category<\/strong>&nbsp;tab, you can find all your existing categories. You can create a new attachment category by clicking the&nbsp;<strong>Add New Category<\/strong>&nbsp;button on the top right corner of the tab.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/add-a-new-category.png\" alt=\"Add new category\" class=\"wp-image-36231\"\/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"product-attachments\">5. Create Product Attachments<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">After creating attachment categories, you can start adding product attachments to them.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For that, go to Manage Attachments using the following path \u2013&nbsp;<strong>Catalog &gt; Product Attachments &gt; Manage Attachments&nbsp;<\/strong>\u2013 and set the appropriate values in the below fields.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Category:<\/strong>&nbsp;Select the&nbsp;<strong>Attachment Category<\/strong>&nbsp;from the dropdown under which you want to list the attachment.<\/li>\n\n\n\n<li><strong>Is Active:<\/strong>&nbsp;Select&nbsp;<strong>Yes<\/strong>&nbsp;to enable the attachment. You can select&nbsp;<strong>No<\/strong>&nbsp;if you need this particular attachment disabled.<\/li>\n\n\n\n<li><strong>Name:<\/strong>&nbsp;Add an appropriate name for the attachment.<\/li>\n\n\n\n<li><strong>Description:<\/strong>&nbsp;Add a meaningful description for this attachment.<\/li>\n\n\n\n<li><strong>Limit number of downloads:<\/strong>&nbsp;Set a limit for the number of downloads for that attachment.<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/create-product-attachments.png\" alt=\"create product attachments\" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<h4 class=\"wp-block-heading\">Uploading a File or Adding a URL for the Attachment<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>File\/URL Switcher:<\/strong>&nbsp;Select the attachment type, whether&nbsp;<strong>File&nbsp;<\/strong>or&nbsp;<strong>URL<\/strong><\/li>\n\n\n\n<li><strong>Files:<\/strong>&nbsp;If you\u2019ve selected&nbsp;<strong>File&nbsp;<\/strong>in the switcher, you can browse and upload the file(s). On the other hand, if you\u2019ve selected the&nbsp;<strong>URL<\/strong>&nbsp;option in the switcher, add the URL in the&nbsp;<strong>URL<\/strong>&nbsp;field.<\/li>\n\n\n\n<li><strong>File Name:<\/strong>&nbsp;The name and size of the browsed file will be displayed here, which you can remove too if you choose to.<\/li>\n\n\n\n<li><strong>Customer Groups:<\/strong>&nbsp;The extension lets you select the customer groups you want to view and download the attachment.<\/li>\n\n\n\n<li><strong>Store View:<\/strong>&nbsp;Select the store views you want to enable the attachment for<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/upload-file-or-url-for-attachment.png\" alt=\"Upload file or add url for attachment\" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<h4 class=\"wp-block-heading\">Assigning Products to Attachment<\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">Now, go to the&nbsp;<strong>Assign Products to Attachment<\/strong>&nbsp;tab on the top left under the&nbsp;<strong>Attachment Information<\/strong>&nbsp;menu and start assigning the products to attachments to display on the frontend.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/assigning-products-to-attachment.png\" alt=\"Assigning Products to attachment\" class=\"wp-image-36231\"\/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">Assigning CMS Pages<\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">Go to the&nbsp;<strong>Assign CMS Page<\/strong>&nbsp;tab under the&nbsp;<strong>Attachment Information<\/strong>&nbsp;menu to assign CMS pages to the attachments you created to show on CMS pages on the frontend.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/assigning-cms-pages.png\" alt=\"Assigning cms pages\" class=\"wp-image-36231\"\/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">Saved Attachments<\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">Once you create a new attachment, it will be shown in the&nbsp;<strong>Manage Attachment<\/strong>&nbsp;tab. To create a new attachment, click on the&nbsp;<strong>Add New Attachment<\/strong>&nbsp;button in the top right corner.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/add-new-attachment.png\" alt=\"Add new attachment\" class=\"wp-image-36231\"\/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"add-attachments\">6. Add Attachments From the Product Edit<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">There is one more way of creating a new attachment directly from the product edit.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Go to&nbsp;<strong>Catalog &gt; Products &gt; Edit Product<\/strong>, and find the&nbsp;<strong>Add Attachments<\/strong>&nbsp;button. Here, you can add new attachments to that particular product.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/add-attachments-from-the-product-edit.png\" alt=\"Add attachments from the product edit\" class=\"wp-image-36231\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">That\u2019s it. Now, your product attachments will be displayed on the frontend.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2024\/07\/product-attachment-seen-on-frontend-after-config.png\" alt=\"Product attachment seen on frontend after config \" class=\"wp-image-36231\"\/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\"><div class=\"meetanshi-cta\">\r\n<div class=\"cta-content-wrapper\">\r\n<span>Magento 2 Product Attachments<\/span>\r\n<p>Add a downloadable product file for shoppers to learn more about your offerings.<\/p>\r\n<a href=\"https:\/\/meetanshi.com\/magento-2-product-attachments.html\" target=\"_blank\" class=\"btn-primary\">Add Files Now<\/a>\r\n<\/div>\r\n<div class=\"cta-image-new\">\r\n<img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2025\/11\/magento-2-product-attachments.png\" alt=\"Magento 2 Product Attachments\">\r\n<\/div>\r\n<\/div><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Help Your Customers Make Informed Decisions<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Adding an attachment in your Magento store is a pretty straightforward task with the right tool at hand, making it easier to show detailed product information directly into the storefront and helping your customers make informed decisions.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A great customer experience is the key to the success of your business, especially when customer expectations are soaring in an evolving market. Unlike in&#8230;<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[34],"tags":[],"class_list":["post-3558","post","type-post","status-publish","format-standard","hentry","category-magento"],"acf":[],"_links":{"self":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/3558","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/comments?post=3558"}],"version-history":[{"count":2,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/3558\/revisions"}],"predecessor-version":[{"id":16825,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/3558\/revisions\/16825"}],"wp:attachment":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/media?parent=3558"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/categories?post=3558"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/tags?post=3558"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}