WordPress Schema Markup Guide - Rich Results for Articles, HowTo, and FAQ

Schema markup tells Google what your content means. How to implement Article, HowTo, FAQ, and BreadcrumbList schema correctly in WordPress.

Dobromir Dechev
Dobromir WordPress agency owner

Schema markup is structured data added to your pages that helps Google understand what type of content it is reading. It does not guarantee rich snippets, but it is a prerequisite for most of them - including star ratings, how-to steps in search results, FAQ accordions in SERPs, and sitelinks search boxes.

This guide covers the most valuable schema types for WordPress content sites and how to implement them correctly.


How schema markup works

Schema.org is a vocabulary created jointly by Google, Bing, and Yahoo. You add schema markup to your HTML using JSON-LD (JavaScript Object Notation for Linked Data) - a script block in the <head> that describes your page content.

Example: a basic Article schema:

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "Article",
  "headline": "WordPress Schema Markup Guide",
  "description": "Schema markup is how you tell Google...",
  "author": {
    "@type": "Person",
    "name": "Agency Owner"
  },
  "datePublished": "2025-01-22",
  "dateModified": "2025-01-22"
}
</script>

JSON-LD is preferred over Microdata because it can be placed in the <head> without modifying the HTML structure. Google recommends it.


Checking your current schema

Before adding schema, check what is already there. Your SEO plugin (Yoast, Rank Math, SEOPress) generates schema automatically. View the current schema on any page:

  1. Go to Google's Rich Results Test (search.google.com/test/rich-results)
  2. Enter your page URL
  3. The tool shows all detected schema types and any errors

Or view the raw JSON-LD by opening page source and searching for application/ld+json.


Article schema

What it enables

Article schema is what qualifies your content for enhanced display in Google News, Top Stories carousel, and other article-focused search features. It also helps Google understand the publication date and authorship.

Implementation via SEO plugin

Rank Math, Yoast, and SEOPress all output Article schema automatically on posts. Verify it includes:

  • headline (page title)
  • description (meta description)
  • author (author name, with Person type)
  • publisher (site name and logo)
  • datePublished (ISO 8601 format)
  • dateModified
  • image (featured image URL)

If any of these are missing in your current schema, the SEO plugin usually has settings to add them. In Rank Math > Titles & Meta > Posts, verify the schema type is set to "Article" (not "None" or "BlogPosting").

Adding missing fields manually

If your SEO plugin does not output all required fields, add a custom schema block in functions.php:

add_action( 'wp_head', function() {
    if ( ! is_singular( 'post' ) ) return;

    global $post;
    $author = get_the_author_meta( 'display_name', $post->post_author );
    $image  = get_the_post_thumbnail_url( $post->ID, 'large' );
    $schema = [
        '@context'      => 'https://schema.org',
        '@type'         => 'Article',
        'headline'      => get_the_title(),
        'datePublished' => get_the_date( 'c' ),
        'dateModified'  => get_the_modified_date( 'c' ),
        'author'        => [ '@type' => 'Person', 'name' => $author ],
        'image'         => $image ?: '',
    ];
    echo '<script type="application/ld+json">' . wp_json_encode( $schema ) . '</script>';
});

HowTo schema

What it enables

HowTo schema can produce rich results showing the steps of a how-to guide directly in search results, with step titles and (sometimes) images. This is particularly effective for tutorial and guide content.

When to use it

Use HowTo schema on posts that are:

  • Step-by-step guides ("How to configure Nginx for WordPress")
  • Repair or fix tutorials ("How to clean a hacked WordPress site")
  • Installation guides ("How to set up a staging environment")

Do not use it on informational articles that are not structured as steps, or on comparison articles.

Manual JSON-LD implementation

add_action( 'wp_head', function() {
    // Only on posts tagged or categorised as HowTo content
    if ( ! is_singular( 'post' ) ) return;
    if ( ! has_tag( 'howto' ) ) return;

    $steps = [
        [ 'name' => 'Step 1 title', 'text' => 'Step 1 description' ],
        [ 'name' => 'Step 2 title', 'text' => 'Step 2 description' ],
        // Add actual steps dynamically from custom fields
    ];

    $how_to_steps = array_map( function( $step ) {
        return [
            '@type' => 'HowToStep',
            'name'  => $step['name'],
            'text'  => $step['text'],
        ];
    }, $steps );

    $schema = [
        '@context' => 'https://schema.org',
        '@type'    => 'HowTo',
        'name'     => get_the_title(),
        'step'     => $how_to_steps,
    ];
    echo '<script type="application/ld+json">' . wp_json_encode( $schema ) . '</script>';
});

For a better workflow: use ACF (Advanced Custom Fields) to create repeater fields for steps on the post type. Then output those fields in the schema dynamically.

Via Rank Math

In Rank Math Pro, you can set schema type to "HowTo" per post and fill in the steps via the schema builder UI. This is the most practical approach for most sites.


FAQ schema

What it enables

FAQ schema can display accordions directly in search results, with expandable questions and answers. This can dramatically increase the amount of SERP real estate your result occupies - often showing 2-4 questions with expandable answers below the main search result.

Google has become more selective about when it shows FAQ rich results, but they still appear for informational content with genuine Q&A structure.

When to use it

Use FAQ schema on:

  • Pages with a dedicated FAQ section
  • Help/support articles
  • Product pages with common questions (great for WooCommerce product pages)

Do not use FAQ schema where the content is not genuinely in Q&A format - Google may ignore the schema or apply a manual action.

JSON-LD implementation

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "FAQPage",
  "mainEntity": [
    {
      "@type": "Question",
      "name": "Does this plugin work with WooCommerce?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "Yes, it integrates fully with WooCommerce 6.0 and above."
      }
    },
    {
      "@type": "Question",
      "name": "Is there a free version?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "The free version covers basic functionality. Premium adds advanced features."
      }
    }
  ]
}
</script>

In WordPress, output this dynamically by parsing an ACF repeater field or a custom metabox where editors add questions and answers.


What it enables

Breadcrumb schema replaces the full URL in search results with a breadcrumb trail: Home > Guides > WordPress SEO. This makes the result look more organised and gives users context about the content's position in the site.

Implementation

Most SEO plugins output BreadcrumbList schema automatically when breadcrumbs are enabled. In Yoast: Settings > Site Basics > Breadcrumbs > Enable. In Rank Math: enable the breadcrumb block in settings.

Verify the output includes:

  • The full path from homepage to current page
  • Each item has name and item (URL) properties

LocalBusiness schema (for agency sites)

If the WordPress site represents a local business or agency, LocalBusiness schema helps local search visibility:

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "ProfessionalService",
  "name": "Your Agency Name",
  "url": "https://yourdomain.com",
  "telephone": "+44-XX-XXXX-XXXX",
  "priceRange": "££",
  "address": {
    "@type": "PostalAddress",
    "streetAddress": "123 Agency Street",
    "addressLocality": "London",
    "postalCode": "EC1A 1BB",
    "addressCountry": "GB"
  },
  "openingHoursSpecification": [
    {
      "@type": "OpeningHoursSpecification",
      "dayOfWeek": ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday"],
      "opens": "09:00",
      "closes": "17:30"
    }
  ]
}
</script>

Add this to your site's homepage via wp_head action in functions.php, conditional on is_front_page().


Testing and validation

After adding schema, validate it:

  1. Google Rich Results Test (search.google.com/test/rich-results) - tests if the page is eligible for rich results and shows warnings
  2. Schema Markup Validator (validator.schema.org) - validates against the full Schema.org specification
  3. Google Search Console > Enhancements - shows rich result counts, errors, and warnings across your entire site after Google crawls the pages

Monitor Search Console regularly for schema errors. A field name typo or missing required property can disqualify all your pages from rich results.


Was this article helpful?