# magefan/module-product-label

> Product Label extension for Magento 2

`composer require magefan/module-product-label`

Canonical URL: https://packagento.com/magefan/module-product-label

## At a glance

- **Vendor**: magefan (https://packagento.com/magefan.md)
- **Latest version**: 2.3.3 — released 2025-09-22
- **Pricing**: Free
- **Package type**: Magento 2 module
- **Status**: active, accepting new buyers

## Installation

Packagento is licence-gated, so even free packages need a licence on a project before Composer can resolve them.

1. **Sign in or create an account** at https://packagento.com/customer/account/.

2. **Add the package to your account.** Open https://packagento.com/magefan/module-product-label and complete the free checkout. A licence is minted automatically.

3. **Create or pick a project, then activate the licence on it.**
   - Projects represent the Magento installs you deploy to. Manage them at https://packagento.com/projects/.
   - Activate the new licence on the project you'll deploy this package to. Activation is what generates the Composer credentials scoped to that project.

4. **Add the project credentials to your Magento codebase.**

   Grab the project's public + private key from https://packagento.com/projects/ (open the project, then its Credentials tab), and add them to `auth.json`:

   ```json
   {
     "http-basic": {
       "packagento.com": {
         "username": "ppk_live_...",
         "password": "psk_live_..."
       }
     }
   }
   ```

   Add the Packagento Composer repository to `composer.json`:

   ```json
   {
     "repositories": [
       { "type": "composer", "url": "https://packagento.com" }
     ]
   }
   ```

5. **Install and apply.**

   ```bash
   composer require magefan/module-product-label:*
   bin/magento setup:upgrade
   bin/magento setup:di:compile
   bin/magento cache:flush
   ```

## What it does

Product Label extension for Magento 2

## README

[![Total Downloads](https://poser.pugx.org/magefan/module-product-label/downloads)](https://packagist.org/packages/magefan/module-product-label)
[![Latest Stable Version](https://poser.pugx.org/magefan/module-product-label/v/stable)](https://packagist.org/packages/magefan/module-product-label)

<img align="right" width="120" height="120" src="https://cm.magefan.com/catalog/product/cache/28b407cef1668fd0bdd6f36db3e8e2f0/i/c/icon-product-labels.jpg">

[Magento 2 Product Labels](https://magefan.com/magento-2-product-labels) is an extension that allows you to drive customers’ attention to specific products with eye-catching labels. Text, shape and image labels - you name it. Magefan Product Labels helps you to create a multitude of product labels in a few clicks and display them using handy conditions.

No need to handle product labels in Magento manually. Just set up the rules once and the extension will display them dynamically across your website pages.

<img  align="right" width="120" height="70" src="https://magefan.com/media/wysiwyg/made_in_ukraine.jpg">


<a href="https://magefan.com/magento-2-product-labels"><img width="190" height="70" src="https://cm.magefan.com/wysiwyg/products/download-magefan-extensions.png"></a>

### Useful Links
  * [User Guide](https://magefan.com/magento-2-product-labels/documentation)
  * [Change Log](https://magefan.com/magento-2-product-labels/change-log)
  * [FAQs](https://magefan.com/magento-2-product-labels#pattr-faq)

### 🇺🇦 Stand with Ukraine! [How can you help?](https://magefan.com/blog/join-our-donations)

### Requirements
  * Magento Community 2.2.0-2.4.x (CE, EE, ECE, B2B)
  * [Magefan Community Extension](https://github.com/magefan/module-community) >= v2.1.14. Please install this extension first if you use installation via FTP.
  * **Note** that extension is free only for the Magento Community (Open Source) Edition. For Magento EE, ECE, B2B you need to purchase the license at magefan.com.

### Editions & Pricing
  
<a href="https://magefan.com/magento-2-product-labels/pricing">
          <img
            src="https://cm.magefan.com/wysiwyg/products/product-label-pricing-plans.png"
            alt="Plans and Pricing for Magento 2 Product Labels Extension" />
        </a>
                
### Benefits
* [Create Text-, Shape- and Image-Based Product Labels in Magento](https://github.com/magefan/module-product-label#create-text--shape--and-image-based-product-labels-in-magento)
* [Use Ready-Made Product Labels Library](https://github.com/magefan/module-product-label#use-ready-made-product-labels-library)
* [Use Conditions to Display Product Labels](https://github.com/magefan/module-product-label#use-conditions-to-display-product-labels)
* [Show Multiple Labels per One Product](https://github.com/magefan/module-product-label#show-multiple-labels-per-one-product)
* [Create Product Labels for Separate Customer Groups](https://github.com/magefan/module-product-label#create-product-labels-for-separate-customer-groups)

### Features

#### Create Text-, Shape- and Image-Based Product Labels in Magento

Magento 2 Product Labels is a robust tool that works dynamically. It helps you to drive attention to certain items and stimulate a purchasing decision. You can create any product labels using this tool 一 text, shape or image. 

A straightforward interface allows you to create labels in Magento in just a few clicks. Then, if you want to adjust the look and feel of those labels using custom CSS or HTML. 

Preview how your label will be displayed on the product, category and other list pages using a preview tool. Choose from a variety of positions or select a custom one. 

<p align="center">
  <img width="853" height="425" src="https://cm.magefan.com/wysiwyg/product-labels-in-magento-2_2.png">
</p>

#### Use Ready-Made Product Labels Library

You can upload any image to create outstanding image labels for your store. You can use the extensive library the Magento 2 Product Label Extension comes with. 

Choose from a variety of labels for any occasion, upload them to the label rules and show them dynamically. The work is reduced to a few steps with the ready-made labels from Magefan.   

<p align="center">
  <img width="853" height="425" src="https://cm.magefan.com/wysiwyg/magento-product-labels.png">
</p>

#### Use Conditions to Display Product Labels

Adding product labels for each product in your store is not even the case. It would be more than time ineffective. That’s why we’ve created Magento 2 Product label rules. 

They allow you to create conditions based on multiple product attributes and define where to display the labels. Show the “New” label on the newly added items and add the “Hot Deal” badge for products with the highest discount. 

Opportunities are limitless. And you can also use dynamic attributes to display labels based on best sellers, review counts and more…

<p align="center">
  <img width="853" height="425" src="https://cm.magefan.com/wysiwyg/product-label-rules-in-magento.png">
</p>

#### Show Multiple Labels per One Product

Do you have a lot to offer to your customers? Tell them about it. Magento 2 Product Labels Extension allows you to add more than one product label to product pages. 

Simply specify the number of labels in the config section and choose different positions for the labels. 

Run several marketing campaigns at the same time to boost sales and attract more customers.

<p align="center">
  <img width="853" height="425" src="https://cm.magefan.com/wysiwyg/multiple-product-labels-in-magento-2.png">
</p>

#### Create Product Labels for Separate Customer Groups

Different customers come to your store with different goals, same as you have something different to offer each of them. By personalizing your offer you make sure each customer finds products that suit their needs. 

Magento 2 Product Labels Extension from Magefan helps with that.

_(README truncated for .md surface. Full README on https://packagento.com/magefan/module-product-label.)_

## Recent Versions

| Version | Released |
|---|---|
| 2.3.3 | 2025-09-22 |
| 2.3.2 | 2025-05-08 |
| 2.3.1 | 2025-03-28 |
| 2.3.0 | 2025-01-23 |
| 2.2.1 | 2024-12-30 |
| 2.2.0 | 2024-12-05 |
| 2.1.4 | 2024-11-13 |
| 2.1.3 | 2024-11-01 |
| 2.1.2 | 2024-09-24 |
| 2.1.1 | 2024-09-11 |

Showing 10 of 13 versions. Full release history on https://packagento.com/magefan/module-product-label.

## Dependencies

### Require

| Package | Constraint |
|---|---|
| magefan/module-community | >=2.2.17 |

## Quality

Latest release (2.3.3) fails the Packagento QA pipeline. Verdicts below are per-cell (Magento line × PHP version) for the matrixed tools, and run-once for the static / security tiers.


### Compatibility

Each Magento line is installed on its supported PHP versions, then the module is built (DI compile + static-content deploy). Cells show passed / failed / untested; staircase gaps render as `–`.

| Magento | PHP 8.2 | PHP 8.3 | PHP 8.4 | PHP 8.5 |
|---|---|---|---|---|
| 2.4.7 | Pass | Pass | – | – |
| 2.4.8 | – | Pass | not tested | – |
| 2.4.9 | – | – | Pass | Pass |


### Code Quality

Advisory checks against the module's source. Never affect the Compatibility verdict — a phpcs finding can't make a module incompatible.

#### Static Analysis

Coding standards (phpcs), mess detection (phpmd), copy-pasted code (cpd), PHP cross-version compatibility, composer.json validity. Each runs once for the whole module.

| Tool | Status | Findings | Summary |
|---|---|---|---|
| PHPCS | Fail | 144 | 1 error, 143 warnings (ruleset: Magento2) — 56 auto-fixable with phpcbf |
| PHPMD | Warning | 19 | 19 rule violations (UnusedFormalParameter:8, IfStatementAssignment:4, CyclomaticComplexity:2, NPathComplexity:2, UnusedLocalVariable:1) |
| Cpd | Pass | 0 |  |
| Composer validate | Warning | 3 | valid with 3 warnings (composer validate --strict) |

#### PHPStan

Type-checks the module against a real Magento install. Re-runs per Magento + PHP version because resolvable symbols differ between releases.

| Magento | PHP 8.2 | PHP 8.3 | PHP 8.4 | PHP 8.5 |
|---|---|---|---|---|
| 2.4.7 | 50 | 50 | – | – |
| 2.4.8 | – | 59 | 59 | – |
| 2.4.9 | – | – | Unknown | Unknown |


### Tests

Unit and integration suites run per Magento + PHP cell. Test failures speak to the module's behaviour, not its compatibility with a line, so they're reported here separately.

#### Unit Tests

| Magento | PHP 8.2 | PHP 8.3 | PHP 8.4 | PHP 8.5 |
|---|---|---|---|---|
| 2.4.7 | N/A | N/A | – | – |
| 2.4.8 | – | N/A | N/A | – |
| 2.4.9 | – | – | N/A | N/A |

#### Integration Tests

| Magento | PHP 8.2 | PHP 8.3 | PHP 8.4 | PHP 8.5 |
|---|---|---|---|---|
| 2.4.7 | N/A | N/A | – | – |
| 2.4.8 | – | N/A | N/A | – |
| 2.4.9 | – | – | N/A | N/A |


### Security

Dependency-advisory audit (composer audit) plus a source malware scan. A malware detection fails the version outright.

| Tool | Status | Findings | Summary |
|---|---|---|---|
| Composer audit | Pass | 0 |  |
| Malware scan | Pass | 0 |  |

## Licence and pricing

Free. A licence is still minted on checkout and bound to your project for Composer access — no payment step.

Refundable within 14 days of first purchase via https://packagento.com/account/refunds/.

## Install via Claude Code or any MCP client

The Packagento MCP server can run the licence + project + Composer steps above in one tool call:

```
purchase_and_install_packages(
  composer_names=["magefan/module-product-label"],
  project_id="proj_xxx"
)
```

This handles cart, checkout, licence minting, project activation, and writes auth.json credentials. Connect a client with `claude mcp add packagento https://mcp.packagento.com`. Full setup at https://packagento.com/docs/mcp-setup.

## Vendor

magefan is a Magento 2 vendor on Packagento. See https://packagento.com/magefan.md for their full catalogue.

