The webshop is almost live, the product range is in Odoo, and then there is still that folder with 800 product photos. Upload them one by one? That will cost you days and at least one case of RSI. Fortunately it can be done in bulk — in two ways, depending on where your photos are now.
Method 1: CSV import with image_1920
- Open the product list and export to CSV with at least id (external ID) and an image_1920 column.
- Fill the image_1920 column for each product with the full URL of the image (for example from your old webshop or a public folder) or with the base64-encoded contents of the file.
- Import the file back in via Favourites → Import records. Odoo fetches the URLs and stores the images against the right product.
This route works fine if your photos are already online somewhere. A bicycle shop moving over from an old webshop can reuse the existing image URLs one-to-one this way.
Methode 2: script via XML-RPC
Are the photos only stored locally, for example as 8719325001234.jpg per article number? Then a small Python script via XML-RPC (or the newer JSON-RPC API) is faster: it looks up the product by default_code (SKU), reads in the file, encodes it to base64 and writes it to image_1920. Always run such a script on a test database or staging environment first — otherwise a typo in the file-name logic will cheerfully attach the wrong photos to hundreds of products.
Optimise first, then import
- A maximum of 1920 pixels wide — larger gives no visible quality benefit, Odoo scales it back down anyway.
- Under 2 MB per file; heavy images noticeably slow down your webshop.
- Batch-compress beforehand with a tool such as TinyPNG or Squoosh.
- Use logical file names (SKU or EAN); that makes the matching error-free.
Finally
Practical tip: import five products first as a trial and check the result in the webshop before you let the full load go. Need help with a product migration or webshop launch in Odoo? Contact DAADit Group, we already have the scripts ready.
The webshop is nearly live, the catalogue is in Odoo, and then there is that folder with 800 product photos. Uploading them one by one? That costs you days and at least one sore wrist. Fortunately it can be done in bulk — in two ways, depending on where your photos live right now.
Method 1: CSV import with image_1920
- Open the product list and export to CSV with at least id (external ID) and a column image_1920.
- Fill the image_1920 column per product with the full URL of the image (for instance from your old webshop or a public folder) or with the base64-encoded content of the file.
- Import the file back via Favorites → Import records. Odoo fetches the URLs and stores each image on the right product.
This route works well when your photos are already online somewhere. A bicycle shop migrating from an old webshop can reuse the existing image URLs one-to-one.
Method 2: a script via XML-RPC
Are the photos only available locally, say as 8719325001234.jpg per article number? Then a small Python script via XML-RPC (or the newer JSON-RPC API) is faster: it looks up each product by default_code (SKU), reads the file, encodes it to base64 and writes it to image_1920. Always run such a script against a test database or staging environment first — one typo in the filename logic will happily attach the wrong photos to hundreds of products.
Optimise first, import second
- Maximum 1920 pixels wide — larger gives no visible quality gain, Odoo scales it down anyway.
- Under 2 MB per file; heavy images noticeably slow down your webshop.
- Batch-compress beforehand with a tool like TinyPNG or Squoosh.
- Use logical file names (SKU or EAN) so the matching is error-free.
One last thing
Practical tip: import five products as a trial first and check the result in the webshop before letting the full batch loose. Need help with a product migration or webshop launch in Odoo? Get in touch with DAADit Group — we already have the scripts on the shelf.