Importing Product Images

Multiple product images of each type can be imported into Magento, and associated with a
specific product. The path and file name of each product image is entered in the CSV file, and
the image files to be imported are uploaded to the corresponding path on the Magento server or
external server, or uploaded to Media Storage.
Magento creates its own directory structure for product images that is organized alphabetically.
When you export product data to a CSV file, you can see the alphabetized path before the file
name of each image. However, when you import images, you typically don’t need to specify a
path, because Magento manages the directory structure automatically. All you need to do is
enter a forward slash before the file name of each image to be imported, and let Magento take
care of the rest.
Review the steps in the import method that you want to use, and run through the process with
a few products. After you understand how it works, you’ll feel confident importing large
quantities of images.
Important! We recommend that you use a program that supports UTF-8 encoding to edit CSV files,
such as Notepad++ or OpenOffice Calc. Microsoft Excel inserts additional characters into the
column header of the CSV file, which can prevent the data from being imported back into Magento.

Method 1: Import Images to Default Path

The easiest way to import product images is to use Dataflow, and let Magento manage the
directory structure. For complete instructions, see Dataflow.

Method 2: Import Images to Specific Path

1. To import image files into a specific path, you must first create the required directory structure
in the media/import folder. The import folder is located on the server in the following
[magento installation folder]/media/import
2. Create the directory structure as follows:
a. Create the parent folder, named for the first character of the image file name.
b. Create a subfolder, named for the second character of the image file name. For example,
the import path for filename.jpg would be as follows:
[magento installation folder]/media/import/f/i/filename.jpg
c. Set the following permissions for all image folders and files:
Image Folders: 0777
Image Files: 0666 (or greater)
On the server, change directories to the media/import folder, and enter the following
from the command line:
find . -type d -exec chmod 777 {} \;
find . -type f -exec chmod 666 {} \;
3. In the CSV file, the image path and file name must be entered in the image, small_image,
and media_image columns for the correct SKU, according to image type. If you want, you can
use the same image for each type.
a. In the appropriate column, enter the relative path to each image in the following format:
Important! Use only lowercase characters in the image path and filename of any image to be
b. Make sure that the correct SKU is entered on each row that has an image file.
4. Complete the standard process to import product data.

Import Guidelines New Entities

Complex Data

If an attribute that is specified in the import file already exists, and its value is derived from a defined
set of values, the following applies:
If the value is not already included in the defined set of values, the row can be imported
and a default value, if defined, is set for the attribute.
If the value is already included in the defined set, the corresponding row cannot be
If an attribute name is specified in the import file but is not yet defined in the system, it is not created,
and its values are not imported.

Invalid Files

A file cannot be imported if all rows are invalid.
A non-existing service data or complex data name is specified in the import file, such as a
column with a “_” heading.

Leave a Comment

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