Skip to main content
seofields
docs

Event Schema

Add Event structured data to your Sanity documents to power rich results for conferences, meetups, concerts, and workshops.

About Event Schema

Event schema powers rich results for conferences, meetups, concerts, and workshops. When properly implemented, Google can display event details directly in search results, including dates, locations, and ticket information, driving more qualified traffic to your event pages.

Fields

FieldTypeRequiredDescription
namestringThe name of the event.
startDatedatetimeThe start date and time of the event in ISO 8601 format.
sponsorstring | objectThe person or organization that sponsors the event — a URL string or a Person/Organization object.
location.namestringThe name of the venue or location where the event takes place.
location.addressstringThe street address of the event location.

Plugin Registration

sanity.config.ts
import { defineConfig } from "sanity";
import { seoFields } from "sanity-plugin-seofields";
import { schemaOrgEventPlugin } from "sanity-plugin-seofields/schema";

export default defineConfig({
  // ...your sanity config
  plugins: [
    seoFields(),
    schemaOrgEventPlugin(),
  ],
});

Schema Usage

Add the schemaOrgEvent field to any document schema:

schemas/page.ts
import { defineField, defineType } from 'sanity'

export default defineType({
  name: 'page',
  title: 'Page',
  type: 'document',
  fields: [
    // ... your other fields
    defineField({
      name: 'schemaOrgEvent',
      title: 'Event Schema',
      type: 'schemaOrgEvent',
    }),
  ],
})

GROQ Query

GROQ query
*[_type == "yourDocument"][0]{
  schemaOrgEvent {
    name,
    startDate,
    sponsor,
    location {
      name,
      address
    }
  }
}

Next.js Component

app/page.tsx
import { EventSchema } from "sanity-plugin-seofields/schema/next";

export default function Page({ data }) {
  return (
    <>
      <EventSchema data={data.schemaOrgEvent} />
      {/* Your page content */}
    </>
  );
}

JSON-LD Output

Generated JSON-LD
{
  "@context": "https://schema.org",
  "@type": "Event",
  "name": "Tech Conference 2025",
  "startDate": "2025-06-15T09:00:00",
  "sponsor": {
    "@type": "Organization",
    "name": "Acme Corp"
  },
  "location": {
    "@type": "Place",
    "name": "Convention Center",
    "address": "123 Main St, San Francisco, CA"
  }
}

Last updated: May 27, 2026. Tested with: Sanity Studio v3, v4, and v5.

Was this page helpful?