How to create Product Category in Magento 2

Last updated on May 31 2022
Raghvendra Wanchoo

Table of Contents

How to create Product Category in Magento 2

Product Categories are the backbone of every online store. A store owner always has to spend the time to research, plan, and create suitable categories for the products. So, the owner can effectively manage their store product. Good product categories not only help a store owner to manage the product, but it also helps the customers to find the product on the online store website easily.

image1 6

It is very easy to create product categories in Magento 2. Content Management System (CMS) in Magento 2 provides lots of support in creating new categories. Before creating the categories, we should have basic knowledge about the root-category and sub-category.

Root-Category and Sub-Category

When we start creating the category structure for a new Magento 2 website, there is only one root category, i.e., Default Category. All the sub-categories are nested below the root category. Root category is the highest level of the catalog, and the online store can have only one root category active at a time.

image2 6

Store products are organized as a sub-category under the root category. We can change the name as well as arrange the position of any root-category or sub-category by using left click and drag them.

Note: Root Category does not become visible to the customer and also does not have a URL key.

Setup the store category in Magento 2

One of the key features of Magento 2 CMS is that it supports for multiple stores. With a single Magento 2 installation, we can host and manage various stores that are completely different from each other. Each store pulls its products from a Root Category. There are some key points, which we need to know while setting up the store category:

  • We need only one root category if we have only one online store.
  • If we are running the various online stores, but all these are selling the same products, in that case, we can assign the same root category to all of them.
  • If we want to have different stores, which carry different products, then we have to create a Root Category for each store.

Once the Root Category is setup, then we can add more sub-categories and also organize our product line. These categories need to be set up first before setting up the store.

How to create Root Category in Magento 2?

To create a root category in Magento 2, follow the below steps:

Step 1: On the sidebar of Admin Panel, Go to Catalog >> Category.

image3 6

Step 2: Click on “Add Root Category” to create the root category.

image4 6
Step 3: Fill the information in required fields such as category name and click on Save.

image5 6

There are six tabs available, which can be used to set options in this root category.

Content – It generally includes the category images and description. We can also add the CMS block here.

Display Setting – It determines how your products are displayed on the category page. So, we can select the way how the category shows up on the frontend.

Search Engine Optimization – Search Engine Optimization for the category includes the URL key, Meta title, Meta keywords, and Meta description.

Product in Category – Here, we assign products to a given category. If we have one store being hosted from our Magento install, this would likely include all of our active products.

Design – It adds our custom design options to a category.

Schedule Design Update – It keeps the schedule updated information.

How to create Sub Category in Magento 2?

Step 1: On the sidebar of Admin Panel, Go to Catalog >> Category.

 

image3 6

Step 2: Firstly click on the Root category under which we want to create a sub-category, and then click on “Add Subcategory” to create the sub-category.

For example: If we want to create a sub-category “B” under the category “A”. First, we need to click on category A, and then click on Add Subcategory.

image6 5
Step 3: Click on the Add Sub Category.

image7 5

Step 4: Fill the information in required fields such as category name and click on Save.

image8 5

Note: Every time you need to select the category under which you want to create a new sub-category.

Step 5: Inside the Content section, we can upload images and description, which will be set as a thumbnail image. While creating a new category, explore the Content section, select the image, and add a description, then click on Save.

image9 3

How to apply New Root Category in your store?

Step 1: On the Admin Panel sidebar, Go to Stores >> All Stores

image10 3

Step 2: Here, click on the Main Website Store.

image11 2

Step 3: Select the root category that you want to assign and then click on the Save Store button.

image12 2

That’s all about how to create a category and configure it in Magento 2. It will be visible like the below screenshot to the customer.

image13 2

So, this brings us to the end of blog. This Tecklearn ‘How to create Product Category in Magento 2’ blog helps you with commonly asked questions if you are looking out for a job in Magento Programming. If you wish to learn Java and build a career Java Programming domain, then check out our interactive, Java and JEE Training, that comes with 24*7 support to guide you throughout your learning period. Please find the link for course details:

https://www.tecklearn.com/course/java-and-jee-training/

Java and JEE Training

About the Course

Java and JEE Certification Training is designed by professionals as per the industrial requirements and demands. This training encompasses comprehensive knowledge on basic and advanced concepts of core Java & J2EE along with popular frameworks like Hibernate, Spring & SOA. In this course, you will gain expertise in concepts like Java Array, Java OOPs, Java Function, Java Loops, Java Collections, Java Thread, Java Servlet, and Web Services using industry use-cases and this will help you to become a certified Java expert.

Why Should you take Java and JEE Training?

  • Java developers are in great demand in the job market. With average pay going between $90,000/- to $120,000/- depending on your experience and the employers.
  • Used by more than 10 Million developers worldwide to develop applications for 15 Billion devices.
  • Java is one of the most popular programming languages in the software world. Rated #1 in TIOBE Popular programming languages index (15th Consecutive Year)

What you will Learn in this Course?

Introduction to Java

  • Java Fundamentals
  • Introduction to Java Basics
  • Features of Java
  • Various components of Java language
  • Benefits of Java over other programming languages
  • Key Benefits of Java

Installation and IDE’s for Java Programming Language

  • Installation of Java
  • Setting up of Eclipse IDE
  • Components of Java Program
  • Editors and IDEs used for Java Programming
  • Writing a Simple Java Program

Data Handling and Functions

  • Data types, Operations, Compilation process, Class files, Loops, Conditions
  • Using Loop Constructs
  • Arrays- Single Dimensional and Multi-Dimensional
  • Functions
  • Functions with Arguments

OOPS in Java: Concept of Object Orientation

  • Object Oriented Programming in Java
  • Implement classes and objects in Java
  • Create Class Constructors
  • Overload Constructors
  • Inheritance
  • Inherit Classes and create sub-classes
  • Implement abstract classes and methods
  • Use static keyword
  • Implement Interfaces and use it

Polymorphism, Packages and String Handling

  • Concept of Static and Run time Polymorphism
  • Function Overloading
  • String Handling –String Class
  • Java Packages

Exception Handling and Multi-Threading

  • Exception handling
  • Various Types of Exception Handling
  • Introduction to multi-threading in Java
  • Extending the thread class
  • Synchronizing the thread

File Handling in Java

  • Input Output Streams
  • Java.io Package
  • File Handling in Java

Java Collections

  • Wrapper Classes and Inner Classes: Integer, Character, Boolean, Float etc
  • Applet Programs: How to write UI programs with Applet, Java.lang, Java.io, Java.util
  • Collections: ArrayList, Vector, HashSet, TreeSet, HashMap, HashTable

Java Database Connectivity (JDBC)

  • Introduction to SQL: Connect, Insert, Update, Delete, Select
  • Introduction to JDBC and Architecture of JDBC
  • Insert/Update/Delete/Select Operations using JDBC
  • Batch Processing Transaction
  • Management: Commit and Rollback

Java Enterprise Edition – Servlets

  • Introduction to J2EE
  • Client Server architecture
  • URL, Port Number, Request, Response
  • Need for servlets
  • Servlet fundamentals
  • Setting up a web project in Eclipse
  • Configuring and running the web app with servlets
  •  GET and POST request in web application with demo
  • Servlet lifecycle
  • Servlets Continued
  • Session tracking and filter
  • Forward and include Servlet request dispatchers

Java Server Pages (JSP)

  • Fundamentals of Java Server Page
  • Writing a code using JSP
  • The architecture of JSP
  • JSP Continued
  • JSP elements: Scriptlets, expressions, declaration
  • JSP standard actions
  • JSP directives
  • Introduction to JavaBeans
  • ServletConfig and ServletContext
  • Servlet Chaining
  • Cookies Management
  • Session Management

Hibernate

  • Introduction to Hibernate
  • Introduction to ORM
  • ORM features
  • Hibernate as an ORM framework
  • Hibernate features
  • Setting up a project with Hibernate framework
  • Basic APIs needed to do CRUD operations with Hibernate
  • Hibernate Architecture

POJO (Plain Old Java Object)

  • POJO (Plain Old Java Object)
  • Persistent Objects
  • Lifecycle of Persistent Object

Spring

  • Introduction to Spring
  • Spring Fundamentals
  • Advanced Spring

Got a question for us? Please mention it in the comments section and we will get back to you.

 

 

0 responses on "How to create Product Category in Magento 2"

Leave a Message

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