Back to Top

Guide for Magento 2 Product Import Using XML URL

Updated 9 January 2025

Magento 2 Product Import Using XML URL extension – The admin just needs to add the XML file URL and then map the XML file column names with the Magento 2 store product column names.

Then when the cron runs the products will get created automatically.

Also, if a new category is assigned to a product that is not available in the store then the category gets created and the product is assigned to the same.

Also, if you are looking to import and export the product reviews then you can check the Magento 2 Product Review Import Export extension.

Check the video mentioned below for an overview of the workflow of this extension:

Searching for an experienced
Magento 2 Company ?
Find out More
sg1JmQybRD0

Features

  • Import simple, virtual, and configurable products using XML URLs provided by the wholesaler or distributors.
  • Import product using cron.
  • Map the product attribute in the admin configuration
  • Enable or disable the extension.
  • Category automatically created and product assigned if the category does not exist.
  • On selecting Weekely: Cron will run on the first day of the week.
  • On selecting Monthly: Cron will run on the first day of the Month.
  •  Import multiple images for products.
  •  Create products with customizable options.
  • Supports MSI functionality.

Installation

#Download Module

Firstly, you need to log in to Webkul Store, go to My Account>My Purchased Products section, verify and then download and extract the contents of this zip folder on the system.

#Upload Folder

Once the module zip extracts, follow path src>app and then copy the app folder into the Magento 2 root directory on the server as shown below:

Magento 2 Product import via XML URL  Installation

# Run Commands

You need to run the following commands:

php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy
php bin/magento indexer:reindex
php bin/magento cache:flush
composer require nicolab/php-ftp-client

Language Translation

For translating the module language, navigate through src/app/code/Webkul/ProductImportXMLUrl/i18n and edit the en_US.csv file.

Thereafter, rename the CSV as “en_SA.csv” and translate all right side content after the comma in the Arabic language. After editing the CSV, save it.

Magento 2 Product import via XML URL   Language Translation

Now, upload it to the path src/app/code/Webkul/ProductImportXMLUrl/i18n where the installation of Adobe commerce is on the server.

The module translates into the Arabic Language. It supports both RTL and LTR languages.

The user can edit the CSV like the image below.

i18_file_transalation-1

Use Case – Magento 2 Product Import Using XML URL

You are running a dropshipping store on Adobe Commerce and work with multiple suppliers, such as D1, D2, and D3, who provide product data.

These suppliers typically share their product information in various file formats, like CSV, which can be cumbersome to manage and upload to your store.

However, if all suppliers use a standardized XML file with a live URL for their product feed, the store admin can easily import these products.

The suppliers can simply update their product details in the XML file and provide the live URL, allowing the store owner to add all the products without much effort.

Initial Configuration

To make the initial configuration settings for the Magento 2 Product Import Using XML URL extension, the admin will navigate through Stores->Configuration->Product Import XML.

webkul product url

Here, the admin will –

  • Enable the module functionality as well as enable the side panel option “Product Import XML” for the extension.
  • Select the attributes of the Adobe commerce store to be mapped with the XML file column names.
webkul product import xml

The Adobe Commerce Attributes that can be mapped with the XML file column names –

  • Categories
  • Description
  • Image Gallery
  • Product Name
  • Price
  • Quantity
  • Short Description
  • SKU
  • Enable Product
  • Tax Class
  • Product Type and
  • Variations
  • Variation Images

Cron Frequency – Cron frequency can be set to Daily, Weekly, or Monthly as required.

webkul magento admin cron frequency
  • On selecting Weekly: Cron will run on the first day of the week.
  • On selecting Monthly: Cron will run on the first day of the Month.

Note:- The Apache2 server must have the “allow_url_fopen” function enabled in php.ini file.

Product Import XML Options

The admin will find two options under the Product Import XML side panel option.

magento webkul product import xml

Workflow

Note: If the XML file exists on the same server then just take the URL of that file and put it in the XML URL field.

For this demonstration, I’ll be using the XML file URL with one product(simple).

XML file:

xml file for product named watch.

Now, navigate to the Add Product XML URL section, enter the XML URL of the file, and save it.

webkul magento add product xml url

After saving the file, a success message for the same is displayed, and the added XML URL gets added.

Also, the column name Attribute Map Status for the newly added XML URL file shows the status as No.

webkul magento product xml url list'

Now we have to map the column names of the XML file with the Adobe Commerce attributes assigned from the configuration settings.

For the respective XML URL file, tap the Map Attribute option.

Here, the admin also has the delete option to delete the XML URL from the list.

webkul import product xml

This brings up the section where you have to go to the Map Attribute section and map the attributes as required.

Lastly, tap the Save button to save the mapping.

map attributes

After saving the Mapping, a success message is displayed as shown below.

Also, now the Attribute Map Status displays the status as Yes.

Supports MSI functionality

After the above procedure, you need to run the below commands in the terminal.

php bin/magento cron:install
php bin/magento cron:run

After running the above commands, products will be created and you can check them in the backend and the storefront.

Backend:

product catlog magento

Storefront:

192.168.15.136_m24657_pub_chronograph-watch.htmlasd

Also, if you want to import the categories into the Magento 2 store in bulk using a CSV/XML/XLS file format then check the Category Bulk Upload Using CSV/XML/XLS for Magento 2 extension.

Demonstration in case of a Configurable Product:

XML file:

For this demonstration, I’ll be using the XML file URL with one product(configurable).

xml file for product named bag

Now, navigate to the Add Product XML URL section, enter the XML URL of the file, and save it.

add product xml url validate

After saving the file, a success message for the same is displayed, and the added XML URL gets added.

Also, the column name Attribute Map Status for the newly added XML URL file shows the status as No.

product xml url list

Now, we have to map the column names of the XML file with the Adobe Commerce attributes assigned from the configuration settings.

To do so, for the respective XML URL file tap the Map Attribute option.

xml url list

This brings up the section where you have to go to the Map Attribute section and map the attributes as required. Lastly, tap the Save button to save the mapping.

add product xml url

After saving the Mapping, a success message is displayed as shown below. Also, now the Attribute Map Status displays the status as Yes.

xml attributes mapped sucesfully

After the above procedure, you need to run the below commands in the terminal.

php bin/magento cron:install
php bin/magento cron:run

After running the above commands, products will be created and you can check them in the backend and the storefront.

Backend:

product catalog attributes

Storefront:

Screenshot-from-2023-08-25-16-07-47

Demonstration of Virtual Product:

XML file:

For this demonstration, I’ll be using the XML file URL with one product(virtual).

xml file for subscription product.

Now, navigate to the Add Product XML URL section, enter the XML URL of the file, and save it.

validate xml url

After saving the file, a success message for the same is displayed, and the added XML URL gets added.

Also, the column name Attribute Map Status for the newly added XML URL file shows the status as No.

xml url list

Now, we have to map the column names of the XML file with the Adobe Commerce attributes assigned from the configuration settings.

To do so, for the respective XML URL file, tap the available Map Attribute option.

webkul magento xml url list

This brings up the section where you have to go to the Map Attribute section and map the attributes as required. Lastly, tap the Save button to save the mapping.

add product xml url

After saving the Mapping, a success message is displayed as shown below. Also, now the Attribute Map Status displays the status as Yes.

xml url list

After the above procedure, you need to run the below commands in the terminal.

php bin/magento cron:install
php bin/magento cron:run

After running the above commands, products will be created and you can check them in the backend and the storefront.

Backend:

product catalog webkul list

Storefront:

192.168.15.136_m24657_pub_subscription-product.htmlasd

Import Product By FTP

Now Navigate to Product Import XML>Import Product By FTP and click on the same as given below.

product import

On clicking the Import Product By FTP button you will come to the similar page below.

You can see Two buttons Sample CSV and Add File Path, Click on Sample CSV and download a Sample CSV file in your local System.

import product by ftp

After Clicking on Sample CSV a CSV file will Download in your local System.

You have to fill the product details in the CSV file and store it in your local system.

Screenshot-from-2024-03-05-17-30-46

Next, click on the Add File Path button in the Import Product By FTP page as given below.

Import-Product-By-FTP-Product-Import-XML-Magento-Admin

After clicking the Add File Path you will land on the page as given below, then you have to fill up the column “Host, Port, Username, Password, File path”.

464

Now, after filling all the columns you have to press the Save button and a File Path Saved Successfully pop-up comes up.

33333

After the above procedure, you need to run the below commands in the terminal.

php bin/magento cron:install
php bin/magento cron:run

After running the above commands, products will be created and you can check them in the backend and the storefront.

Backend:

99999

Storefront:

212121

Support

That is all about the Magento 2 Product import Using XML URL extension. If you have any queries regarding the plugin, please contact us at Webkul Support System.

If you’re looking to create a custom e-commerce website, it’s a great idea to hire Magento developers who can help you build a powerful and scalable online store.

You can also check our complete Magento 2 extensions.

Current Product Version - 4.0.3

Supported Framework Version - Magento 2.0.x, 2.1.x, 2.2.x,2.3.x, 2.4.x

. . .

Leave a Comment

Your email address will not be published. Required fields are marked*


Be the first to comment.

Back to Top

Message Sent!

If you have more details or questions, you can reply to the received confirmation email.

Back to Home

Table of Content