PHPackages                             justbetter/statamic-structured-data - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. justbetter/statamic-structured-data

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

justbetter/statamic-structured-data
===================================

2.0.0(1mo ago)45.6k↓42.6%4[2 PRs](https://github.com/justbetter/statamic-structured-data/pulls)PHPPHP ^8.4|^8.5CI passing

Since Apr 25Pushed 1mo ago5 watchersCompare

[ Source](https://github.com/justbetter/statamic-structured-data)[ Packagist](https://packagist.org/packages/justbetter/statamic-structured-data)[ RSS](/packages/justbetter-statamic-structured-data/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (16)Versions (22)Used By (0)

[ ![Banner](./art/banner.svg)](github.com/justbetter/statamic-structured-data "JustBetter")Statamic Structured Data
========================

[](#statamic-structured-data)

This Statamic addon provides a powerful and flexible way to add structured data (JSON-LD) to your Statamic website. It allows you to define structured data templates and automatically inject them into your pages, improving your site's SEO and making your content more understandable for search engines.

Features
--------

[](#features)

- 🔄 Dynamic JSON-LD generation based on entry and term data
- 📝 Template-based structured data configuration
- 🔌 Automatic injection of structured data into your pages
- 🎯 Support for multiple schemas per page
- 🛠 Antlers template parsing support
- 💪 Flexible and extensible architecture

Requirements
------------

[](#requirements)

- PHP ^8.2 or ^8.3
- Laravel ^11.0
- Statamic ^5.0

Installation
------------

[](#installation)

You can install this addon via Composer:

```
composer require justbetter/statamic-structured-data
```

After installing make sure to load the Structured Data tag in your head.

**Blade**:

```
{!! Statamic::tag('structured-data:head')->fetch() !!}
```

**Antlers**

```
{{ structured-data:head }}
```

Configuration
-------------

[](#configuration)

Make sure to publish the config by running:

```
php artisan vendor:publish --tag=justbetter-structured-data
```

You can now find the config file at `config/justbetter/structured-data.php`. After publishing the config, you can set the collections and taxonomies that should have structured data templates.

Usage
-----

[](#usage)

### 1. Creating Structured Data Templates

[](#1-creating-structured-data-templates)

Create templates in your Statamic control panel that define your structured data schemas. Each template can contain multiple schema definitions with:

- Special properties (@context, @type, @id)
- Custom fields with various data types (strings, numeric, arrays, objects)
- Dynamic values using Antlers templating syntax

### 2. Assigning Templates to Entries

[](#2-assigning-templates-to-entries)

In your entry or term's content, you can assign one or more structured data templates using the `structured_data_templates` field. The addon will automatically process these templates and generate the appropriate JSON-LD scripts.

### 3. Automatic Injection

[](#3-automatic-injection)

The addon automatically injects the generated JSON-LD scripts into your pages before the closing `` tag. No additional configuration is required.

Example Schema
--------------

[](#example-schema)

Here's an example of how you might structure a basic Organization schema:

```
{
  "specialProps": {
    "context": "https://schema.org",
    "type": "Organization",
    "id": "https://example.com"
  },
  "fields": [
    {
      "key": "name",
      "type": "string",
      "value": "{{ company_name }}"
    },
    {
      "key": "url",
      "type": "string",
      "value": "{{ config:app:url }}"
    }
  ]
}
```

Credits
-------

[](#credits)

- [Kevin Meijer](https://github.com/kevinmeijer97)
- [All Contributors](../../contributors)

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE) for more information.

[ ![JustBetter logo](./art/footer.svg)](https://justbetter.nl "JustBetter")

###  Health Score

53

—

FairBetter than 97% of packages

Maintenance89

Actively maintained with recent releases

Popularity31

Limited adoption so far

Community17

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 92% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~22 days

Recently: every ~31 days

Total

16

Last Release

55d ago

Major Versions

1.x-dev → 2.0.02026-03-24

PHP version history (2 changes)1.0.0PHP ^8.2|^8.3

2.0.0PHP ^8.4|^8.5

### Community

Maintainers

![](https://www.gravatar.com/avatar/2d00b3f55cd4ae8b8cfb001a644ed6c7a1127a956c24375bcfe16ce12bd89bed?d=identicon)[justbetter](/maintainers/justbetter)

---

Top Contributors

[![kevinmeijer97](https://avatars.githubusercontent.com/u/9716909?v=4)](https://github.com/kevinmeijer97 "kevinmeijer97 (81 commits)")[![royduin](https://avatars.githubusercontent.com/u/1703233?v=4)](https://github.com/royduin "royduin (3 commits)")[![JoeyMckenzie](https://avatars.githubusercontent.com/u/16873254?v=4)](https://github.com/JoeyMckenzie "JoeyMckenzie (2 commits)")[![BobWez98](https://avatars.githubusercontent.com/u/23509926?v=4)](https://github.com/BobWez98 "BobWez98 (1 commits)")[![martingoldie](https://avatars.githubusercontent.com/u/725238?v=4)](https://github.com/martingoldie "martingoldie (1 commits)")

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/justbetter-statamic-structured-data/health.svg)

```
[![Health](https://phpackages.com/badges/justbetter-statamic-structured-data/health.svg)](https://phpackages.com/packages/justbetter-statamic-structured-data)
```

###  Alternatives

[wireui/wireui

TallStack components

1.8k1.3M16](/packages/wireui-wireui)[statamic-rad-pack/runway

Eloquently manage your database models in Statamic.

135192.6k5](/packages/statamic-rad-pack-runway)[marcorieser/statamic-livewire

A Laravel Livewire integration for Statamic.

2381.5k10](/packages/marcorieser-statamic-livewire)[ramonrietdijk/livewire-tables

Dynamic tables for models with Laravel Livewire

21147.4k](/packages/ramonrietdijk-livewire-tables)[swiftmade/statamic-clear-assets

Deletes unused assets. Saves storage space.

1938.6k](/packages/swiftmade-statamic-clear-assets)[aerni/livewire-forms

A Statamic forms framework powered by Laravel Livewire

2912.8k](/packages/aerni-livewire-forms)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
