Akeneo Auto Category Assignment Rules: This module simplifies the process of assigning categories to products.
You can now use this module to build many rules with the conditions and categories you want.
After you’ve created the rules, all you have to do now is hit the play button to start the work.
Following project completion, the selected categories will be assigned to the products in accordance with the condition set up.
Features
- Assign products to multiple categories at once.
- For category assignments, add multiple conditions.
- For auto-assignment, the product must match all conditions or any condition.
- When creating rules for category assignment, you can select local and channel.
- For rule creation, actions such as empty, not empty, equal to, contains, and others are available.
Basic Requirement
- This module works with Akeneo 3.2,4.0.x, and 5.0.x. Download Akeneo from here
- This module is compatible with the Akeneo community and Enterprise(Flexibility) edition.
- If you want to use this extension on Akeneo EE Serenity mode, please contact us.
- For the Akeneo installation, your Akeneo server should meet these system requirements.
Installing Module for Version 4.0.x to 5.0.x
1- Composer Installation -For Version 5 only
Run the composer install command:
composer require webkul/automaticcategoryassignmentbundle
2- Manual Installation
Please follow these steps for installing the Akeneo Auto Category Assignment Rules module in your Akeneo PIM platform.
1 – Unzip the respective extension zip then merge the “src” folder into the akeneo project root directory.

2 – Goto config/Bundles.php then add the line:
Webkul\AutomaticCategoryAssignmentBundle\AutomaticCategoryAssignmentBundle::class => ['all' => true],
in the return array.
3 – Copy the “config” folder into akeneo project root directory for routing.

4 – Run this command after ssh to your akeneo server by the terminal
php bin/console automatic_category_assignment:setup:install
5. If you are using php-fpm. Then you need to restart the php-fpm services and apache web server.
For Akeneo 5
sudo service php-fpm7.4 restart
For Akeneo 4
sudo service php-fpm7.3 restart
Docker Installation Command :
For Akeneo 5
alias docker_php='docker-compose run -u www-data --rm php php';
alias docker_yarn='docker-compose run -u node --rm node yarn';
docker_php bin/console cache:clear --env=prod;
docker_php bin/console pim:installer:assets --symlink --clean --env=prod;
docker_php bin/console d:s:u --force;
docker_yarn run webpack;
docker_yarn run update-extensions;
docker_yarn run less;
For Akeneo 4
alias docker_php='docker-compose run -u www-data --rm php php';
alias docker_yarn='docker-compose run -u node --rm node yarn';
docker_php bin/console cache:clear --env=prod;
docker_php bin/console pim:installer:assets --symlink --clean --env=prod;
docker_php bin/console d:s:u --force;
docker_yarn run webpack;
docker_yarn run less;
Installing Module For Version 3.x
Please follow these steps for installing the Akeneo Auto Category Assignment Rules module in your Akeneo PIM platform.
1 – Unzip the respective extension zip then merge the “src” folder into akeneo project root directory.
2 – Goto app/AppKernel.php then add a line.
new Webkul\AutomaticCategoryAssignmentBundle\AutomaticCategoryAssignmentBundle(),
3 – Goto app/config/routing.yml then add these lines at top of the file.
AutomaticCategoryAssignment:
resource: "@AutomaticCategoryAssignmentBundle/Resources/config/routing.yml"
prefix: /
4 – Run this command after ssh to your akeneo server by the terminal
php bin/console automatic_category_assignment:setup:install
5. If you are using php-fpm. Then you need to restart the php-fpm services and apache web server.
sudo service php-fpm7.2 restart
Common Issues After Installation

It might happen that even after proper installation, upon opening your Akeneo admin dashboard, you see a loading screen. In that case, do check for the following solution:
- Webpack Installation: If you get the below error It means that web pack is not installed in your system. Run the following commandnpm install –save-prod webpack npm install
- Module routing.yml is not configured properly. Re-check the routing.yml file as mentioned in the 3rd step of Module Installation
- Clear your browser cache.
Workflow – Auto Category Assignment Rules
Go to the Akeneo Dashboard when you’ve finished installing the module. On the left side of the screen, there is an icon for Webkul Auto Category Assignment Rules.

The user can easily define a new condition for category assignment under the Auto Category Assignment Rules tab. Aside from that, the user can see the rules that have previously been created. Aside from that, the user can edit or delete the conditions.
Create a New Condition
There are two options for documentation and conditions after you click the tab assignment.
After that, go to Conditions>>Create to make new conditions.

Properties:
Following that, the user will enter the code for the condition by clicking the create rules button.
Products must match – If the user wants to match any of the conditions from the produced condition, they must select any condition; if they want to match all conditions, they must select all conditions.
Channel and Locale – Then you must choose the channel and locale where the user wants to run the condition.

Then click the “Add” button. The user will then select an attribute as the basis for the rule’s condition.

The user will now choose the rule condition to apply to the attribute after selecting the attribute.

After that, you must add the value to the attribute, such as name in the condition attribute, where the name should be sunglasses, and the category will be assigned to the product.

Categories Selection:
After you’ve added all of the condition properties, you’ll need to choose the category to which this rule will be assigned. To do so, go to Categories Selection and then Edit.

After you’ve selected all of the categories, click the Confirm button.

Execute Rule
Finally, the user will save the condition and be able to view it under the condition.

After that, the user will run the condition and must confirm before proceeding.

The user will see a success message for the rule when it has been executed.

Applied Condition – Product
The user can now look at the product’s condition. All of the selected categories have been assigned the product name sunglasses.

If you want to get more information on the execution process, go to Dasboard>>. Process Tracker

Then, by clicking on the job, you can look through the details.

Support
So, that was much about the User Guide of Auto Category Assignment Rules for any queries or doubts reach out to us at support@webkul.com. You can also raise a ticket at our HelpDesk System.
Please explore our Akeneo Development Services and Quality Akeneo Extensions.