obah sylva

Custom WordPress Theme Development: Where to Start in 2026

Share this article

Custom WordPress theme development in 2026 starts with a block theme built on theme.json and HTML block templates, not a classic PHP-template theme — that’s the single biggest shift from how theme development worked even three or four years ago. If you’re starting a new theme today, the right entry point is a minimal starter block theme, a theme.json file that defines your design tokens, and template parts assembled in the Site Editor, with PHP still available for anything block markup can’t express.

Classic Themes vs. Block Themes

A classic theme uses PHP template files (header.php, footer.php, single.php, page.php) and the Template Hierarchy to decide which file renders a given URL, with styling controlled through a style.css file and the Customizer. A block theme replaces most of that with HTML template files made of block markup, a theme.json file that defines colors, typography, and spacing as design tokens, and the Site Editor for visual layout changes — no Customizer, no widgets.php.

AspectClassic themeBlock theme
TemplatesPHP files (single.php, page.php)HTML files in /templates/ built from blocks
Stylingstyle.css + Customizertheme.json design tokens + Site Editor
Header/footerheader.php, footer.phpTemplate parts edited visually in the Site Editor
Client editingLimited to Customizer options you buildFull visual editing of layout, not just content
Best forHighly custom PHP logic, legacy codebasesNew builds, client-editable layouts, faster iteration

Neither approach is obsolete. Classic themes still make sense when a project leans heavily on custom PHP logic, a page builder like Elementor, or a legacy codebase you’re maintaining rather than rebuilding. But for a new theme built from scratch in 2026, a block theme is the default starting point.

Laptop displaying a custom website homepage, representing custom WordPress theme development
A custom theme controls both the visual design and the underlying markup a site is built on.

Where to Actually Start

  1. Start from a minimal starter theme, not from scratch. The official Twenty Twenty-Five (or the current default theme) and community starters like Create Block Theme’s generated output give you a working style.css, theme.json, and template folder structure instead of an empty directory.
  2. Define your design tokens in theme.json first. Colors, font sizes, spacing scale, and layout widths all belong here as reusable presets, not hardcoded values scattered through templates — this is what makes the Site Editor’s controls actually match your design system.
  3. Build template parts before full templates. Header and footer as reusable template parts, then assemble index.html, single.html, and page.html from them plus core blocks (Post Title, Post Content, Query Loop).
  4. Register only what core doesn’t already give you. Custom block styles, custom patterns, and PHP for anything block markup genuinely can’t do (custom REST endpoints, custom post types, complex conditional logic) still belong in functions.php.
  5. // A minimal theme.json color and typography setup
    {
      "$schema": "https://schemas.wp.org/trunk/theme.json",
      "version": 3,
      "settings": {
        "color": {
          "palette": [
            { "slug": "primary", "color": "#1a1a1a", "name": "Primary" },
            { "slug": "accent", "color": "#2563eb", "name": "Accent" }
          ]
        },
        "typography": {
          "fontSizes": [
            { "slug": "medium", "size": "1rem", "name": "Medium" },
            { "slug": "large", "size": "1.5rem", "name": "Large" }
          ]
        }
      }
    }

    Custom Post Types and Fields Still Matter

    Block themes changed how templates are built, not how data is modeled. Custom post types (register_post_type), taxonomies (register_taxonomy), and custom fields still live in PHP, and a Query Loop block can pull from any registered post type just as easily as from regular posts. Advanced Custom Fields (or the block-bindings API introduced in recent WordPress versions) still handles structured custom data that needs to render inside block templates.

    PHP template code in an editor, representing WordPress theme template files
    PHP is still where custom post types, taxonomies, and anything block markup can’t express live.

    Performance and SEO Basics to Get Right From Day One

    • Enqueue assets correctly. Use wp_enqueue_script() and wp_enqueue_style() hooked to wp_enqueue_scripts, never hardcoded <script> tags in a template — this is what lets caching plugins and dependency management actually work.
    • Keep theme.json lean. Every color, font size, and spacing value you register generates CSS custom properties on every page load; only register what the design actually uses.
    • Support proper title tags and meta. A custom theme should call wp_head() and wp_footer() in every template — skipping these breaks Yoast SEO, Site Kit, and most other plugins silently.
    • Test with Core Web Vitals in mind. A custom theme with no page builder overhead is usually faster than a heavily-plugin-dependent build, but only if images use proper srcset sizing and render-blocking scripts are avoided.
    • Deciding If a Custom Theme Is the Right Call

      A custom theme makes sense when an off-the-shelf theme or page builder can’t hit a specific design, performance, or content-modeling requirement, and the project has the budget for real development time rather than configuration. If the site will run dynamic, JavaScript-driven features on top of WordPress content, you’ll likely be pairing theme templates with REST API calls — see our WordPress REST API guide for how that layer works. And if the goal is eventually to decouple the frontend entirely, our WordPress vs Next.js comparison covers when that trade-off is worth making instead of building a custom theme at all.

      Not sure a custom theme is the right call for this project? See Elementor vs Custom Code: When Should a Developer Build Custom?.

      Need a custom WordPress theme built for your business? See Next.js & WordPress web development services

Leave a Comment

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

Scroll to Top