Using custom taxonomy in custom post types means that you can add categories, or tags to your custom posts.

This can be achieved with code like the following – added to your custom post type plugin or via the custom post type definition in your functions.php file:

This makes a taxonomy available with the slug “categories” – whereas the standard WordPress loop would use “category”. In this case, it is intentionally different to show that you can name this whatever you want. This means that you could use the following code, if for example you wanted to show all the “websites” in your portfolio custom post type:

Image Credit: --Tico--