Schema
Image Schema
On this page
Schema.org Image
- Type:
defineImage<T extends Record<string, any>>(input?: ImageObject & T)
Describes an individual image (usually in the context of an embedded media object).
Useful Links
Required properties
- url or contentUrl
string
The image file URL. Relative URLs become absolute.
Google image metadata
For licensable images, add creator, creditText, copyrightNotice, and at least one of license or acquireLicensePage. Unhead resolves a nested creator as a Person or Organization and makes license URLs absolute.
Defaults
- @type:
ImageObject - @id:
${canonicalHost}#/schema/image/{n} - inLanguage:
inLanguagefrom resolved page metadata - contentUrl:
url
Resolves
See Global Resolves for full context.
creatorresolves as a Person or OrganizationlicenseandacquireLicensePagebecome absolute URLswidthandheightmust be provided for either to be included
Examples
Minimal
defineImage({
url: '/cat.jpg',
})
Types
interface ImageBase extends Thing {
caption?: string
height?: number
width?: number
inLanguage?: string
name?: string
description?: string
encodingFormat?: string
creator?: NodeRelations<Identity>
creditText?: string
copyrightNotice?: string
license?: string
acquireLicensePage?: string
}
type ImageLocation
= | { url: string, contentUrl?: string }
| { url?: string, contentUrl: string }
export type ImageSimple = ImageBase & ImageLocation
Did this page help you?
HowTo Schema - JSON-LD Guide & Examples
Add HowTo structured data with Unhead, including step-by-step JSON-LD, images, supplies, tools, and time estimates.
ItemList Schema - JSON-LD Guide & Examples
Add ItemList structured data with Unhead. Create ordered lists and eligible Google carousels for courses, movies, recipes, and restaurants.