Use case

Import AliExpress reviews to your PrestaShop store

A product page without reviews converts worse. Pull the reviews your supplier already has as JSON and load them into PrestaShop’s own product comments.

Get a free API keyRead the docs

Reviews that live in your catalogue

PrestaShop stores reviews in the table of its Product Comments module, so the stars, the average and the structured data of your product pages come from there. Importing into that table means no extra module and no iframe from a third party.

The API gives you the same reviews AliExpress shows on the product page, with the same filters, in a stable JSON format, instead of a scraper that breaks every few weeks.

How it works

  1. Find the AliExpress product ID in the URL: the number in aliexpress.com/item/1005006123456789.html.
  2. Choose the reviews: 4 and 5 stars (two requests with filter=5 and filter=4), only with photos, or from your customers’ country with filter=local.
  3. Translate them with lang to the language of each shop view: es_ES, fr_FR, it_IT…
  4. Insert them into the product comments table, marked as validated, with the original date.

Example: from AliExpress to PrestaShop product comments

A standalone PHP script you can run from the command line on your server. It loads PrestaShop, reads the 5-star reviews and inserts them for one product. Check the column names against your version of the Product Comments module before running it on production.

PHP — reviews to PrestaShop
<?php
// Insert the 5-star reviews of an AliExpress product as PrestaShop product comments.
// Run it from the command line on your server, after backing up the database.
require_once __DIR__ . '/config/config.inc.php';

$idProduct = 42; // your PrestaShop product
$ch = curl_init('https://api.aliexpress-reviews.com/v1/reviews/1005006123456789?filter=5&pageSize=20');
curl_setopt_array($ch, [
    CURLOPT_HTTPHEADER => ['x-api-key: ' . getenv('REVIEWS_API_KEY')],
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_TIMEOUT => 30,
]);
$body = curl_exec($ch);
if (curl_getinfo($ch, CURLINFO_HTTP_CODE) !== 200) {
    exit("Request failed\n");
}
$reviews = json_decode($body, true)['data'];

foreach ($reviews as $r) {
    Db::getInstance()->insert('product_comment', [
        'id_product' => (int) $idProduct,
        'id_customer' => 0,
        'id_guest' => 0,
        'customer_name' => pSQL($r['author']),
        'title' => pSQL(mb_substr($r['content'], 0, 60)),
        'content' => pSQL($r['content']),
        'grade' => (int) $r['rating'],
        'validate' => 1,
        'deleted' => 0,
        'date_add' => pSQL($r['date'] . ' 12:00:00'),
    ]);
}

Details worth getting right

  • Back up first. Test on a copy of the database: the table schema depends on the version of the module.
  • Keep the API key out of the front office. Run it from a CLI script or a cron job, never from a template.
  • Avoid duplicates by saving the AliExpress review ids you already imported, for example in a small table or file.
  • Photos (filter=image, Max plan): the response includes image URLs if you want to show them in the description or download them.

Use them honestly

Show them as reviews of the product from AliExpress buyers, not from your customers. Consumer law in the EU requires you to say where your reviews come from, and it is also what builds trust.

Questions

Does it work with PrestaShop 1.7 and 8?

The API is independent of your PrestaShop version. What changes is the schema of the Product Comments module, so check the column names of the table in your install before importing.

Can I use a different review module?

Yes. The API returns JSON, so you can map the fields (rating, text, author, date) to the table or import format of any review module.

How many reviews can I get?

Up to 20 per request on Free and up to 100 on Pro and Max, with pagination to go through all of them. The quota is 100, 1,000 or 10,000 requests a day depending on the plan.

Is the API affiliated with AliExpress?

No. It returns the public reviews AliExpress shows on its product pages, but it is an independent service.

Try it with your own products

100 requests a day for free, no card required. Paste a product ID into the tester in your dashboard and see the JSON.

Get a free API keyPricing