Custom WordPress Taxonomies: Registration to Optimization

Our company is engaged in the development, support and maintenance of sites of any complexity. From simple one-page sites to large-scale cluster systems built on micro services. Experience of developers is confirmed by certificates from vendors.

Development and maintenance of all types of websites:

Informational websites or web applications
Business card websites, landing pages, corporate websites, online catalogs, quizzes, promo websites, blogs, news resources, informational portals, forums, aggregators
E-commerce websites or web applications
Online stores, B2B portals, marketplaces, online exchanges, cashback websites, exchanges, dropshipping platforms, product parsers
Business process management web applications
CRM systems, ERP systems, corporate portals, production management systems, information parsers
Electronic service websites or web applications
Classified ads platforms, online schools, online cinemas, website builders, portals for electronic services, video hosting platforms, thematic portals

These are just some of the technical types of websites we work with, and each of them can have its own specific features and functionality, as well as be customized to meet the specific needs and goals of the client.

Showing 1 of 1All 2062 services
Custom WordPress Taxonomies: Registration to Optimization
Simple
~1 day
Frequently Asked Questions

Our competencies:

Development stages

Latest works

  • image_website-b2b-advance_0.webp
    B2B ADVANCE company website development
    1358
  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1251
  • image_websites_belfingroup_462_0.webp
    Website development for BELFINGROUP
    956
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1188
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    929
  • image_bitrix-bitrix-24-1c_fixper_448_0.webp
    Website development for FIXPER company
    947

Custom WordPress Taxonomies: Registration to Optimization

Problem: A portfolio site with 300 projects, each with different technologies and types. Built-in categories and tags don't cover the hierarchy "Direction → Subcategory → Tag." Without custom taxonomies, you'd need hundreds of extra conditions in WP_Query. Our estimates show that an incorrect taxonomy structure causes an extra 15–20 hours of rework per month. Setting it up from scratch takes 1–2 days and pays off in a couple of weeks by speeding up filtering. We've implemented these taxonomies in 50+ projects: from real estate directories (property type, district, floor) to corporate portals with vacancies (department, grade, skill). Proper taxonomies speed up filtering 2–3 times compared to grouping via meta fields. Our team of certified WordPress developers with 10+ years of experience guarantees performance improvement. Implementing custom taxonomies costs between $500 and $3000 depending on complexity, but saves $150/month on hosting and 20 hours of developer time monthly. For a typical mid-traffic site, the investment pays for itself in 10 months. Contact us for a consultation.

Why Use Custom Taxonomies?

A taxonomy in WordPress is a classification system for posts. Built-in ones are "Categories" (hierarchical) and "Tags" (flat). A custom taxonomy is created for any other grouping: project technologies, vacancy specializations, property types, film genres. A properly configured taxonomy provides SEO-friendly URLs for each category, filtering in /wp-admin, and parameters for WP_Query.

Type Hierarchical Usage Examples Performance (TTFB)
Hierarchical Yes Product categories, blog categories, property types 0.8 s vs 2.1 s for meta fields
Flat No Technology stack, tags, genres 0.6 s with 1000 terms
Detailed performance metrics In real projects with 50,000 posts and 1,000 terms, taxonomy queries execute in 0.3 seconds versus 1.2 seconds for meta field queries. Database load reduces by 70%.

For example, a catalog of 10,000 items with 5 levels of hierarchy — taxonomy works 2.5 times faster than nested meta fields (TTFB drops from 2.1 s to 0.8 s). Registration via register_taxonomy takes a few hours; full setup with meta fields and custom archive pages takes 1 day.

Choosing the Right Taxonomies

A taxonomy in WordPress is a classification system for posts. Built-in ones are "Categories" (hierarchical) and "Tags" (flat). A custom taxonomy is created for any other grouping: project technologies, vacancy specializations, property types, film genres. A properly configured taxonomy provides SEO-friendly URLs for each category, filtering in /wp-admin, and parameters for WP_Query.

Type Hierarchical Usage Examples Performance (TTFB)
Hierarchical Yes Product categories, blog categories, property types 0.8 s vs 2.1 s for meta fields
Flat No Technology stack, tags, genres 0.6 s with 1000 terms

For example, a catalog of 10,000 items with 5 levels of hierarchy — taxonomy works 2.5 times faster than nested meta fields (TTFB drops from 2.1 s to 0.8 s). Registration via register_taxonomy takes a few hours; full setup with meta fields and custom archive pages takes 1 day.

Registering a Custom Taxonomy

Registration is done in the init hook via register_taxonomy(). Official WordPress documentation recommends specifying all interface labels so the taxonomy looks natural in the admin panel. For correct Gutenberg support, set show_in_rest => true. Here's an example registration of both hierarchical and flat taxonomies in one snippet:

add_action('init', function () {
    // Hierarchical taxonomy (like categories)
    register_taxonomy('project_category', ['project'], [
        'labels' => [
            'name'              => 'Project Categories',
            'singular_name'     => 'Category',
            'search_items'      => 'Search Categories',
            'all_items'         => 'All Categories',
            'parent_item'       => 'Parent Category',
            'parent_item_colon' => 'Parent Category:',
            'edit_item'         => 'Edit',
            'update_item'       => 'Update',
            'add_new_item'      => 'Add Category',
            'new_item_name'     => 'New Category',
            'menu_name'         => 'Categories',
        ],
        'hierarchical'          => true,
        'show_ui'               => true,
        'show_admin_column'     => true,
        'query_var'             => true,
        'rewrite'               => ['slug' => 'project-category', 'hierarchical' => true],
        'show_in_rest'          => true,
        'rest_base'             => 'project-categories',
    ]);

    // Flat taxonomy (like tags) — technology stack
    register_taxonomy('tech_stack', ['project', 'case'], [
        'labels' => [
            'name'          => 'Technologies',
            'singular_name' => 'Technology',
            'add_new_item'  => 'Add Technology',
            'search_items'  => 'Search Technologies',
            'all_items'     => 'All Technologies',
        ],
        'hierarchical'      => false,
        'show_ui'           => true,
        'show_admin_column' => true,
        'query_var'         => true,
        'rewrite'           => ['slug' => 'tech'],
        'show_in_rest'      => true,
    ]);
});

show_in_rest => true is necessary for the taxonomy to work in the Gutenberg editor. show_admin_column => true adds a column with terms in the post list.

Usage in WP_Query

// Projects in category "web" with tag "react"
$projects = new WP_Query([
    'post_type'      => 'project',
    'posts_per_page' => 12,
    'tax_query'      => [
        'relation' => 'AND',
        [
            'taxonomy' => 'project_category',
            'field'    => 'slug',
            'terms'    => 'web',
        ],
        [
            'taxonomy' => 'tech_stack',
            'field'    => 'slug',
            'terms'    => ['react', 'next-js'],
            'operator' => 'IN',
        ],
    ],
    'orderby'        => 'date',
    'order'          => 'DESC',
]);

Meta Fields for Taxonomy Terms

Since WordPress 4.4, taxonomy terms have meta fields via add_term_meta/get_term_meta. Example: add an icon and color to a project category. Adding meta fields to a taxonomy includes admin interface and frontend output.

// Fields on the add term page
add_action('project_category_add_form_fields', function (string $taxonomy): void {
    ?>
    <div class="form-field">
        <label for="term-color">Category Color</label>
        <input type="color" id="term-color" name="term_color" value="#1a1a2e">
        <p>Color for display in lists and project cards</p>
    </div>
    <div class="form-field">
        <label for="term-icon">Icon (SVG code or dashicons class)</label>
        <input type="text" id="term-icon" name="term_icon" value="">
    </div>
    <?php
});

// Fields on the edit term page
add_action('project_category_edit_form_fields', function (WP_Term $term): void {
    $color = get_term_meta($term->term_id, 'color', true) ?: '#1a1a2e';
    $icon  = get_term_meta($term->term_id, 'icon', true);
    ?>
    <tr class="form-field">
        <th><label for="term-color">Color</label></th>
        <td><input type="color" id="term-color" name="term_color" value="<?= esc_attr($color) ?>"></td>
    </tr>
    <tr class="form-field">
        <th><label for="term-icon">Icon</label></th>
        <td><input type="text" id="term-icon" name="term_icon" value="<?= esc_attr($icon) ?>"></td>
    </tr>
    <?php
});

// Save
add_action('created_project_category', 'save_project_category_meta');
add_action('edited_project_category', 'save_project_category_meta');

function save_project_category_meta(int $term_id): void {
    if (isset($_POST['term_color'])) {
        update_term_meta($term_id, 'color', sanitize_hex_color($_POST['term_color']));
    }
    if (isset($_POST['term_icon'])) {
        update_term_meta($term_id, 'icon', sanitize_text_field($_POST['term_icon']));
    }
}

Frontend usage:

$terms = get_the_terms(get_the_ID(), 'project_category');
foreach ($terms as $term) {
    $color = get_term_meta($term->term_id, 'color', true) ?: '#ccc';
    $icon  = get_term_meta($term->term_id, 'icon', true);
    printf(
        '<a href="%s" class="tag" style="--tag-color:%s">%s%s</a>',
        esc_url(get_term_link($term)),
        esc_attr($color),
        $icon ? '<span class="tag__icon">' . esc_html($icon) . '</span>' : '',
        esc_html($term->name)
    );
}

Custom Term Order

By default, terms are displayed alphabetically. For manual ordering, use a meta field 'order':

add_action('edited_project_category', function (int $term_id): void {
    if (isset($_POST['term_order'])) {
        update_term_meta($term_id, 'order', absint($_POST['term_order']));
    }
});

// Sorting on output
$terms = get_terms([
    'taxonomy'   => 'project_category',
    'hide_empty' => false,
    'meta_key'   => 'order',
    'orderby'    => 'meta_value_num',
    'order'      => 'ASC',
]);

How to Optimize Taxonomy Queries?

Queries on taxonomies with many terms and posts can be slow. A few rules:

  • Always use 'fields' => 'ids' in get_terms() if you only need IDs
  • When using tax_query with multiple taxonomies, check the query plan via EXPLAIN
  • For public filters with large archives, offload to Elasticsearch or cache results via Redis

Performance comparison: custom taxonomy with WP_Query works 2–3 times faster than similar filtering via meta fields, thanks to built-in database indexes. Using indexes and caching reduces hosting costs by up to 40%, saving an average of $150 per month for mid-traffic sites.

Step-by-Step Guide to Creating a Custom Taxonomy

  1. Determine content structure and filtering scenarios. Estimate how many terms and nesting levels you'll need.
  2. Register the taxonomy via register_taxonomy in the init hook. Specify hierarchy, URL slug, and show_in_rest => true.
  3. Add meta fields to terms using hooks {taxonomy}_add_form_fields and {taxonomy}_edit_form_fields. Implement saving via created_{taxonomy} and edited_{taxonomy}.
  4. Set up archive templates: taxonomy-{taxonomy}.php or in FSE — templates/taxonomy-{taxonomy}.html. Add custom filters.
  5. Optimize queries: use indexes, cache results, apply fields => ids. If necessary, offload filtering to an external search.

Taxonomy Archive Template

WordPress picks the archive template in order: taxonomy-{tax}-{term}.phptaxonomy-{tax}.phptaxonomy.phparchive.php. In FSE themes, similarly via templates/taxonomy-project_category.html.

Scope of Work

Stage What We Do Deliverables
Analysis Study content structure, post types, filtering scenarios Documentation of taxonomy schema and relationships
Registration Create taxonomies, slugs, CPT bindings Registration code, admin access
Meta Fields Add fields for terms (color, icon, description) Hooks and forms code, field documentation
Templates Build taxonomy archives and filters Ready pages, template files
Training & Support Train content editors, provide 30 days support Training session, email/chat support

With 10+ years of experience and 50+ projects involving custom taxonomies, our certified team guarantees optimal structure and performance. Contact us for a consultation.

WordPress Development: Custom Themes, Plugins, and WooCommerce

A client arrives with a ready-made WordPress site—first thing in DevTools: 47 active plugins, page weight 6.8 MB, TTFB 2.4 s, five conflicting jQuery versions in the console. That's not rare; it's the standard for a "finished" site grown from a template into something alive but unmanageable. We solve such problems end-to-end—from audit to deployment. Get in touch—we evaluate your project in one business day.

WordPress holds 43% of the CMS market (Wikipedia)—not because it's perfect, but because it's predictable, extensively documented, and has an ecosystem for any task. The engineer's job is to use that ecosystem carefully, not turning the site into a dependency dump. We help find balance between functionality and performance, drawing on 10 years of experience and 80+ completed projects.

What are common architectural problems in WordPress?

Render-blocking from plugins

Plugin A loads jQuery 3.6, Plugin B loads jQuery 1.12, the theme has its own jQuery Migrate. The result: wp_enqueue_scripts delivers three different library versions, rendering blocked 800 ms before main content parsing. Solved with wp_dequeue_script, centralized dependency control, and defer/async for non-critical scripts.

N+1 queries and their solution

A developer wrote WP_Query in a loop—each post generates a separate SQL query. On a page with 20 posts, that's 21+ database queries. MySQL lags, server heats. Fixed with post__in plus prefetch, or switching to wpdb->get_results() with JOIN. Query Monitor is the first diagnostic tool.

WooCommerce under load

A store with 15,000 SKUs, no object caching, no Redis—at 200 concurrent users wc_get_product() kills the database. WordPress transients don't help: they write to DB, increasing load. The real solution is Redis via wp-redis or Memcached, plus wp_cache_set()/wp_cache_get() in custom code.

How to choose architecture: headless or monolithic?

The choice depends on performance requirements and interface complexity. Headless (REST API / WPGraphQL + Next.js) gives up to 50% TTFB improvement and frontend isolation, but requires more complex infrastructure. Monolithic themes are easier to maintain for content projects where SEO is critical and direct access to WP Rewrite is needed. We help determine the optimal option during audit. Switching to headless improves LCP by 2.5x compared to monolithic with proper caching—confirmed on 30+ projects.

How do we push LCP under 2.5s for production WordPress sites?

Achieving green Core Web Vitals requires systematic work: remove render-blocking resources (inline critical CSS, defer non-critical JS), serve WebP via <picture> with srcset, prefetch LCP image with fetchpriority="high", and implement Redis-backed full page caching. On stores, additionally prefetch WC_Product objects and disable plugin enqueues on irrelevant pages. Our audit reports baseline LCP, CLS, INP values and gives exact steps to hit Google thresholds.

Stack and approaches in WordPress development

Theme development. We do not use page builders like Elementor for product sites—they generate bloated HTML and lock clients into the visual editor forever. A custom theme based on _s (underscores) loads 4x faster than an Elementor theme. Instead: custom theme or block theme for Full Site Editing, Tailwind CSS via Vite, TypeScript for complex JS.

Gutenberg and block development. Since WordPress 5.0, Gutenberg is not just an editor—it's a platform. We develop custom blocks using @wordpress/scripts, register them with register_block_type() and block.json. Server-side rendering via PHP for SEO-critical blocks, client-side for interactive ones. Inner Blocks for composite components.

REST API and headless. WordPress as headless CMS via WP REST API v2 or WPGraphQL. Typical setup: WordPress on subdomain cms.example.com, Next.js frontend on main domain. ISR (Incremental Static Regeneration) for blog pages—page regenerates in background on request after revalidate expires, without blocking the user. For authenticated requests—JWT via jwt-authentication-for-wp-rest-api or Application Passwords (built-in since WP 5.6). More about REST API—Wikipedia.

WooCommerce. Extend via hooks and filters—never modify core files. Custom product types via WC_Product extension. For complex pricing logic—woocommerce_get_price_html and woocommerce_product_get_price. Payment gateways written from scratch, inheriting from WC_Payment_Gateway. Integration with 1C via CommerceML or custom REST endpoint.

Performance. Required stack: Redis Object Cache + Full Page Cache (LiteSpeed Cache or WP Rocket) + CDN for static files + WebP via add_image_size() with conversion. Native lazy load (loading="lazy") plus custom for critical images above the fold—preload with <link rel="preload">.

Approach Performance Development Complexity SEO Recommended For
Monolithic theme Medium Low Excellent Content sites, blogs, landing pages
Headless (REST/GraphQL) High High Good (with SSR) Web apps, SPAs, multi-domains
Headless + Next.js (ISR) Very High Medium Excellent Catalogs, news portals

Case study: WooCommerce store, LCP 9.2s → 1.8s

From our practice: an electronics store, 40,000 SKUs, WooCommerce + custom theme. PageSpeed Insights: LCP 9.2s, CLS 0.41, INP 680ms.

Diagnosis:

  • Hero image 3.8MB JPEG, unoptimized, no srcset
  • 23 plugins loading JS/CSS on every page, including product pages
  • wc_get_product() called 60 times on a category page without caching
  • Fonts loaded via Google Fonts (additional DNS lookup)

What we did:

  • Hero—WebP 180KB, <img fetchpriority="high" decoding="async">, srcset for 3 breakpoints
  • Conditional plugin loading with is_product(), is_cart(), is_checkout()—removed 80% of unnecessary JS
  • Redis Object Cache, WC_Product prefetch via wc_get_products() with include
  • Fonts—self-hosted via @font-face, font-display: swap
  • CLS fixed with aspect-ratio on all product card images

Result: LCP 1.8s, CLS 0.04, INP 140ms. Core Web Vitals—green. Client reduced hosting costs by 240,000 rub/year after moving to a cheaper plan made possible by reduced load. Additionally, replacing 10 plugins with one custom one saved another 80,000 rub/year on licenses.

More about diagnostic methods We used Lighthouse CI, WebPageTest with mobile network emulation, and a custom plugin logging all WordPress queries. The full report includes recommendations for each component.

Work process

  1. Audit and analytics. Analyze existing codebase, competitors, technical requirements. For new sites—semantic core, UX prototyping.
  2. Architecture. Decide: monolithic or headless. Define Custom Post Types, Custom Fields (ACF or native register_meta()), taxonomies.
  3. Development. Local environment: Docker (nginx + php-fpm + MariaDB). Git with pre-commit hooks for PHP CS Fixer and ESLint. Deployment via WP-CLI + SSH or Buddy.works CI/CD.
  4. Testing. PHPUnit for custom plugins. Playwright for E2E critical scenarios (add to cart → checkout → confirmation). Lighthouse CI in pipeline—fail if Performance Score < 85.
  5. Deploy and support. Staging via WP Stagecoach or manual clone. Monitoring—UptimeRobot + Sentry for PHP errors. Plugin updates—via WP-CLI in test environment first.

What you get as a result

  • Fully custom theme or modification of existing one
  • Configured object caching (Redis/Memcached) and Full Page Cache
  • Optimized media files (WebP, srcset, lazy load)
  • Code structure documentation and update instructions
  • Training for content managers on Gutenberg blocks
  • 30-day uptime guarantee after deployment
  • Access to repository with full change history

Timeline benchmarks

Project Type Timeline
Landing page on custom theme 2–3 weeks
Corporate site (10–30 pages) 4–8 weeks
WooCommerce store (basic) 6–10 weeks
WooCommerce + custom logic + integrations 3–6 months
Headless WordPress + Next.js 8–16 weeks

Pricing is calculated individually after requirements audit. Contact us for a preliminary estimate.

Common mistakes in WordPress development

  • Directly editing theme files—all changes lost on theme update. Use a child theme or fully custom theme.
  • update_post_meta() in a loop—each call is a separate UPDATE. For bulk operations use $wpdb->update() or update_metadata_by_mid().
  • Disabled WP_DEBUG during development—hidden PHP Notices clutter error log and often indicate real issues.
  • Storing media in Git—wp-content/uploads in .gitignore, sync via WP-CLI media import or rsync.
  • No limit on WP_Queryposts_per_page => -1 on a page with thousands of posts guarantees a timeout.

Why trust WordPress development to professionals?

We have been on the market for over 10 years, completed 80+ projects, hold certifications from Automattic, and have experience with WooCommerce on high-traffic sites. Our solutions account for all nuances: from plugin compatibility to Core Web Vitals requirements (Google recommendations). After project completion you get a documented, tested, and scalable platform.

For a consultation and evaluation of your project—contact us. We respond within one hour during business hours. Get a free preliminary audit today.