gatsbyjs/gatsby · error

Type `${typeName}` declared in `createTypes` looks like a no

Error message

Type `${typeName}` declared in `createTypes` looks like a node, but doesn't implement a `Node` interface. It's likely that you should add the `Node` interface to your type def:

`type ${typeName} implements Node { ... }`

If you know that you don't want it to be a node (which would mean no root queries to retrieve it), you can explicitly disable inference for it:

`type ${typeName} @dontInfer { ... }`

What it means

Error "Type `${typeName}` declared in `createTypes` looks like a node, but doesn't implement a `Node` interface. It's likely that you should add the `Node` interface to your type def: `type ${typeName} implements Node { ... }` If you know that you don't want it to be a node (which would mean no root queries to retrieve it), you can explicitly disable inference for it: `type ${typeName} @dontInfer { ... }`" thrown in gatsbyjs/gatsby.

Source

Thrown at packages/gatsby/src/schema/infer/index.js:50

        ? typeComposer.getExtension(`infer`)
        : true
      if (runInfer) {
        if (!typeComposer.hasInterface(`Node`)) {
          noNodeInterfaceTypes.push(typeName)
        }
        typesToInfer.push(typeComposer)
      }
    } else {
      typeComposer = ObjectTypeComposer.create(typeName, schemaComposer)
      addNodeInterface({ schemaComposer, typeComposer })
      typeComposer.setExtension(`createdFrom`, `inference`)
      typesToInfer.push(typeComposer)
    }
  })

  if (noNodeInterfaceTypes.length > 0) {
    noNodeInterfaceTypes.forEach(typeName => {
      report.warn(
        `Type \`${typeName}\` declared in \`createTypes\` looks like a node, ` +
          `but doesn't implement a \`Node\` interface. It's likely that you should ` +
          `add the \`Node\` interface to your type def:\n\n` +
          `\`type ${typeName} implements Node { ... }\`\n\n` +
          `If you know that you don't want it to be a node (which would mean no ` +
          `root queries to retrieve it), you can explicitly disable inference ` +
          `for it:\n\n` +
          `\`type ${typeName} @dontInfer { ... }\``
      )
    })
    report.panic(`Building schema failed`)
  }

  return typesToInfer.map(typeComposer =>
    addInferredType({
      schemaComposer,
      typeComposer,
      typeConflictReporter,

View on GitHub (pinned to e85d62f177)

Solutions

  1. Add the Node interface to the type definition, e.g. `type MyType implements Node { ... }` in createTypes
  2. If the type intentionally should not be a node, disable inference with the `@dontInfer` directive, e.g. `type MyType @dontInfer { ... }`
  3. Check for typos in the type name given to createTypes so the intended node type is actually defined
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at packages/gatsby/src/schema/infer/index.js:50 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of gatsbyjs/gatsby@e85d62f177 (2026-08-26). Data as JSON: /api/errors/9c49023869abbc77. Report an issue: GitHub.