How can one entity have several types in JSON-LD?

The Citead team, updated

In short. Use an array under @type when one JSON-LD node has several types.

Definition: In JSON-LD, a node can have several types by giving @type an array of type IRIs or context terms. During expansion, those values describe multiple type relationships for the same node.

Key facts

  • The W3C JSON-LD 1.1 specification says that a node can be assigned more than one type by using an array.
  • The W3C example expands two listed types into two rdf:type statements for the same node.
  • Google's documentation, last updated 10 December 2025, says Google Search supports JSON-LD when the markup is valid and properly implemented for the documented structured data feature, and recommends the format when a site's setup allows it.

What does an array under @type mean?

@type identifies the type of a node. The JSON-LD specification says that types are uniquely identified with an IRI. A compacted document may use terms from the active context, while an expanded document writes the corresponding IRIs.

For a single node, the array means that both type relationships apply to that node:

{
  "@id": "http://me.markus-lanthaler.com/",
  "@type": [
    "http://schema.org/Person",
    "http://xmlns.com/foaf/0.1/Person"
  ]
}

The W3C example labels this pattern “Specifying multiple types for a node”. Its statements list the node once with schema:Person and once with foaf:Person. The array therefore does not create two nodes. It adds two types to one node.

The values of @type are unordered, according to the same specification. Their order does not express priority or inheritance. A list is a different JSON-LD construct for data whose order has meaning.

How should the values be written?

Each array item must resolve to a type IRI. You can write a full IRI directly, as in the W3C example, or use a term defined in the active context. The specification says that the value of an @type key may be a term defined in that context. A compacted version can therefore look like this:

{
  "@context": {
    "Person": "http://schema.org/Person",
    "FoafPerson": "http://xmlns.com/foaf/0.1/Person"
  },
  "@id": "http://me.markus-lanthaler.com/",
  "@type": ["Person", "FoafPerson"]
}

The context supplies the meaning of the terms. JSON-LD also allows the properties of a graph node to be spread across different node objects, where processing merges the keys into the resulting node.

Do not confuse a node's types with the datatype of a literal value. The W3C specification says that @type can set either a node type or the datatype of a typed value, but value objects are restricted to one type. An array of several values belongs to the node case.

How can you check this on a website?

Google's structured data introduction lists JSON-LD as a supported format and says that the Rich Results Test can validate structured data. First check that the JSON is valid and that the @type value is an array inside the intended node object. Then check that every term in the array is defined by the active context or is already an IRI.

Google's documentation also says that JSON-LD can be placed in a script element in the head or body, and that Google can read it when JavaScript injects it into the page contents.

The Google page explains which properties have special meaning to Google Search, while the W3C specification defines the JSON-LD syntax. A valid array is therefore a syntax fact; it does not by itself establish eligibility for a particular Search feature.

FAQ

Can @type be a string or an array?

Yes. A single type can use one value, while several types use an array. The W3C specification's expanded form represents node types as an array, including when the array contains one type.

Does the order of the types matter?

No. The W3C specification states that the values of @type are unordered. Use @list for an explicitly ordered collection, rather than relying on the position of items in a type array.

Is this the same as giving a value several datatypes?

No. The specification distinguishes node types from typed values and restricts a value object to one type. The array in this entry belongs to a node object.

Sources

  1. W3C, "JSON-LD 1.1", 16 July 2020
  2. Google Search Central, "Intro to How Structured Data Markup Works", 10 December 2025

Check how a page reads to answer engines. Open the GEO score analyzer

Test a page and see what to fix first

The analysis usually takes less than 10 seconds and needs no account.

400,000+ pages scored in the public benchmark