Vacation Rental Page Schema
The page for one place to stay: a VacationRental with eight photos, a map position, the Accommodation it holds, guest rating and reviews, on a page published by the Organization from the homepage.
When To Use It
Use on the page for one rental property a guest can book. Vacation rental results are only open to sites in Google's program, which asks for a Google Technical Account Manager and Hotel Center access. Outside the program the markup is still valid, and earns no result.
Google needs a name, a listing ID, eight photos that show a bedroom, a bathroom and a common area, a map position to five decimal places, and how many guests the place sleeps. Without all of them the builder outputs nothing.
Frameworks On This Page
Each card opens the framework for that feature, with its own rules and property reference. Cards marked "Linked by @id" are defined on the homepage and only referenced here.
Vacation Rental
On this page. The rental, with its photos, position and one Accommodation. Schema framework OpenReview Snippet
On this page. Guest rating and dated reviews. Schema framework OpenBreadcrumb
On this page. Home, Cabins, Spruce Cove Cabin. Schema framework OpenOrganization
Linked by @id. Publisher of the page, by @id from the homepage. Schema framework OpenHow The Pieces Connect
Every node has a stable @id. A node is written out once, where it belongs, and everywhere else it is referenced by that @id alone. This is the map for this page, generated from the output below.
| @id | Defined on | Type | Referenced by |
|---|---|---|---|
/cabins/spruce-cove/#webpage | This page | WebPage | Top-level node |
/cabins/spruce-cove/#breadcrumb | This page | BreadcrumbList | WebPage.breadcrumb |
/cabins/spruce-cove/#rental | This page | VacationRental | WebPage.mainEntity |
/#organization | Homepage | OnlineStore | WebPage.publisher |
/#website | Homepage | WebSite | WebPage.isPartOf |
The Builder
One function turns the page's data into the whole graph. It drops anything Google would reject instead of shipping it half built. The input below includes rows it is meant to drop, so you can see the logic work.
// Vacation rental page schema: the page for one place to stay. A
// VacationRental with its photos, map position, the one Accommodation it
// holds, guest rating and reviews, plus the page's WebPage, published by
// the Organization from the homepage, and its BreadcrumbList.
//
// Google needs a name, a listing ID, eight photos that show a bedroom, a
// bathroom and a common area, a map position to five decimal places, and
// how many guests the place sleeps. Without all of them the builder outputs
// nothing.
const COUNTRY = /^[A-Z]{2}$/;
const ISO_DATE = /^\d{4}-\d{2}-\d{2}$/;
const TIME = /^\d{2}:\d{2}(:\d{2})?([+-]\d{2}:\d{2}|Z)?$/;
const LANGUAGE = /^[A-Za-z]{2,3}(-[A-Za-z0-9]{2,8})*$/;
const clean = (v) => (typeof v === 'string' ? v.trim() : v);
const isUrl = (v) => typeof v === 'string' && /^https:\/\/[^\s]+$/.test(v);
const compact = (obj) => {
if (Array.isArray(obj)) {
const out = obj.map(compact).filter((v) => v !== undefined);
return out.length ? out : undefined;
}
if (obj && typeof obj === 'object') {
const out = {};
for (const [k, v] of Object.entries(obj)) {
const c = compact(v);
if (c !== undefined) out[k] = c;
}
return Object.keys(out).length ? out : undefined;
}
return obj === null || obj === '' ? undefined : obj;
};
function breadcrumb(trail, id) {
const items = (trail || []).filter((c) => c.name && isUrl(c.url));
if (items.length < 2) return undefined;
return {
'@type': 'BreadcrumbList',
'@id': id,
itemListElement: items.map((c, i) => ({ '@type': 'ListItem', position: i + 1, name: clean(c.name), item: c.url })),
};
}
const num = (v) => (typeof v === 'number' && Number.isFinite(v) ? v : null);
// A rating only counts with a score inside its scale and a count above zero.
function aggregateRating(r) {
if (!r) return undefined;
const best = num(r.best) ?? 5;
const worst = num(r.worst) ?? 1;
const value = num(r.value);
if (value === null || worst >= best || value < worst || value > best) return undefined;
if (!(num(r.count) > 0)) return undefined;
return { '@type': 'AggregateRating', ratingValue: value, bestRating: best, worstRating: worst, ratingCount: r.count };
}
// A map position Google can place: a number with five or more decimals.
const coordinate = (v) => (num(v) !== null && /^-?\d+\.\d{5,}$/.test(String(v)) ? v : undefined);
// A guest review needs a named author, a score inside its scale and the date
// it was written.
function review(r) {
const author = clean(r.author);
const best = num(r.best) ?? 5;
const worst = num(r.worst) ?? 1;
const value = num(r.rating);
if (!author || author.length >= 100 || !ISO_DATE.test(r.date || '')) return undefined;
if (value === null || worst >= best || value < worst || value > best) return undefined;
return compact({
'@type': 'Review',
author: { '@type': 'Person', name: author },
reviewRating: { '@type': 'Rating', ratingValue: value, bestRating: best, worstRating: worst },
datePublished: r.date,
contentReferenceTime: ISO_DATE.test(r.stayed || '') ? r.stayed : undefined,
});
}
const RENTAL_TYPES = ['Apartment', 'Bungalow', 'Cabin', 'Chalet', 'Cottage', 'Gite', 'HolidayVillageRental', 'House', 'Villa', 'VacationRental'];
const PLACE_TYPES = ['EntirePlace', 'PrivateRoom', 'SharedRoom'];
const FLOOR_UNITS = ['FTK', 'SQFT', 'MTK', 'SQM'];
const YES_NO_AMENITIES = [
'ac', 'airportShuttle', 'balcony', 'beachAccess', 'childFriendly', 'crib', 'elevator', 'fireplace',
'freeBreakfast', 'gymFitnessEquipment', 'heating', 'hotTub', 'instantBookable', 'ironingBoard', 'kitchen',
'microwave', 'outdoorGrill', 'ovenStove', 'patio', 'petsAllowed', 'pool', 'privateBeachAccess',
'selfCheckinCheckout', 'smokingAllowed', 'tv', 'washerDryer', 'wheelchairAccessible', 'wifi',
];
const CHOICE_AMENITIES = {
internetType: ['Free', 'Paid', 'None'],
parkingType: ['Free', 'Paid', 'None'],
poolType: ['Indoor', 'Outdoor', 'None'],
};
// Only amenities from Google's list, each with the kind of value it takes.
function amenities(list) {
const out = [];
for (const [name, value] of Object.entries(list || {})) {
if (YES_NO_AMENITIES.includes(name) && typeof value === 'boolean') out.push({ name, value });
else if ((CHOICE_AMENITIES[name] || []).includes(value)) out.push({ name, value });
else if (name === 'licenseNum' && value) out.push({ name, value: String(value) });
}
return out.map((a) => ({ '@type': 'LocationFeatureSpecification', ...a }));
}
function buildVacationRentalPageSchema(source) {
const site = source.site || {};
const page = source.page || {};
const rental = source.rental || {};
const unit = rental.unit || {};
if (!isUrl(site.url) || !isUrl(page.url) || !rental.name || !rental.listingId) return null;
// Eight photos, with a bedroom, a bathroom and a common area among them.
const photos = (rental.photos || []).filter((p) => isUrl(p.url));
const shown = new Set(photos.map((p) => p.shows));
if (photos.length < 8 || !['bedroom', 'bathroom', 'common'].every((room) => shown.has(room))) return null;
const latitude = coordinate(rental.latitude);
const longitude = coordinate(rental.longitude);
if (latitude === undefined || longitude === undefined) return null;
if (!Number.isInteger(unit.sleeps) || unit.sleeps < 1) return null;
const root = site.url.replace(/\/+$/, '');
const pageUrl = page.url;
const rentalId = `${pageUrl}#rental`;
const address = rental.address || {};
const place = compact({
'@type': 'VacationRental',
'@id': rentalId,
additionalType: RENTAL_TYPES.includes(rental.type) ? rental.type : undefined,
name: clean(rental.name),
identifier: clean(String(rental.listingId)),
url: pageUrl,
description: clean(rental.description),
// Google reads brand as the listing's brand ID in Hotel Center.
brand: rental.hotelCenterBrand ? { '@type': 'Brand', name: clean(rental.hotelCenterBrand) } : undefined,
image: photos.map((p) => p.url),
latitude,
longitude,
address: {
'@type': 'PostalAddress',
streetAddress: clean(address.street),
addressLocality: clean(address.city),
addressRegion: clean(address.region),
postalCode: clean(address.postalCode),
addressCountry: COUNTRY.test(address.country || '') ? address.country : undefined,
},
checkinTime: TIME.test(rental.checkin || '') ? rental.checkin : undefined,
checkoutTime: TIME.test(rental.checkout || '') ? rental.checkout : undefined,
knowsLanguage: (rental.hostLanguages || []).filter((l) => LANGUAGE.test(l)),
containsPlace: {
'@type': 'Accommodation',
additionalType: PLACE_TYPES.includes(unit.kind) ? unit.kind : undefined,
occupancy: { '@type': 'QuantitativeValue', value: unit.sleeps },
numberOfBedrooms: num(unit.bedrooms) ?? undefined,
numberOfBathroomsTotal: num(unit.bathrooms) ?? undefined,
numberOfRooms: num(unit.rooms) ?? undefined,
floorSize: num(unit.floorArea) > 0 && FLOOR_UNITS.includes(unit.floorUnit)
? { '@type': 'QuantitativeValue', value: unit.floorArea, unitCode: unit.floorUnit }
: undefined,
bed: (unit.beds || [])
.filter((b) => Number.isInteger(b.count) && b.count > 0 && b.type)
.map((b) => ({ '@type': 'BedDetails', numberOfBeds: b.count, typeOfBed: clean(b.type) })),
amenityFeature: amenities(unit.amenities),
},
aggregateRating: aggregateRating(rental.rating),
review: (rental.reviews || []).map(review).filter(Boolean),
});
const crumbs = breadcrumb(page.breadcrumbs, `${pageUrl}#breadcrumb`);
const webpage = compact({
'@type': 'WebPage',
'@id': `${pageUrl}#webpage`,
url: pageUrl,
name: clean(page.title) || clean(rental.name),
isPartOf: { '@id': `${root}/#website` },
publisher: { '@id': `${root}/#organization` },
breadcrumb: crumbs ? { '@id': crumbs['@id'] } : undefined,
mainEntity: { '@id': rentalId },
});
return { '@context': 'https://schema.org', '@graph': [webpage, crumbs, place].filter(Boolean) };
}
{
"site": {
"url": "https://www.example.com"
},
"page": {
"url": "https://www.example.com/cabins/spruce-cove/",
"title": "Spruce Cove Cabin | Harbor & Pine Cabins",
"breadcrumbs": [
{
"name": "Home",
"url": "https://www.example.com/"
},
{
"name": "Cabins",
"url": "https://www.example.com/cabins/"
},
{
"name": "Spruce Cove Cabin",
"url": "https://www.example.com/cabins/spruce-cove/"
}
]
},
"rental": {
"name": "Spruce Cove Cabin",
"listingId": "HPC-0412",
"type": "Cabin",
"hotelCenterBrand": "harbor-and-pine-cabins",
"description": "Two-bedroom cabin on Moosehead Lake with a wood stove, a dock and a screened porch.",
"photos": [
{
"url": "https://www.example.com/img/cabins/spruce-cove/exterior.jpg",
"shows": "exterior"
},
{
"url": "https://www.example.com/img/cabins/spruce-cove/living-room.jpg",
"shows": "common"
},
{
"url": "https://www.example.com/img/cabins/spruce-cove/kitchen.jpg",
"shows": "common"
},
{
"url": "https://www.example.com/img/cabins/spruce-cove/bedroom-1.jpg",
"shows": "bedroom"
},
{
"url": "https://www.example.com/img/cabins/spruce-cove/bedroom-2.jpg",
"shows": "bedroom"
},
{
"url": "https://www.example.com/img/cabins/spruce-cove/bathroom.jpg",
"shows": "bathroom"
},
{
"url": "https://www.example.com/img/cabins/spruce-cove/porch.jpg",
"shows": "common"
},
{
"url": "https://www.example.com/img/cabins/spruce-cove/dock.jpg",
"shows": "exterior"
},
{
"url": "/img/cabins/spruce-cove/floor-plan.jpg",
"shows": "other"
}
],
"latitude": 45.46012,
"longitude": -69.59147,
"address": {
"street": "41 Cove Road",
"city": "Greenville",
"region": "ME",
"postalCode": "04441",
"country": "US"
},
"checkin": "16:00:00-05:00",
"checkout": "10:00:00-05:00",
"hostLanguages": [
"en-US",
"fr-CA"
],
"unit": {
"kind": "EntirePlace",
"sleeps": 5,
"bedrooms": 2,
"bathrooms": 1.5,
"rooms": 5,
"floorArea": 1150,
"floorUnit": "FTK",
"beds": [
{
"type": "Queen",
"count": 1
},
{
"type": "Single",
"count": 2
},
{
"type": "Sofa bed",
"count": 0
}
],
"amenities": {
"wifi": true,
"kitchen": true,
"fireplace": true,
"petsAllowed": false,
"parkingType": "Free",
"sauna": true,
"licenseNum": "Greenville STR-2026-118"
}
},
"rating": {
"value": 4.9,
"count": 86
},
"reviews": [
{
"author": "Priya Raman",
"rating": 5,
"date": "2026-08-02",
"stayed": "2026-07-24"
},
{
"author": "Tom Baird",
"rating": 4,
"date": "",
"stayed": "2026-06-10"
}
]
}
}
{
"@context": "https://schema.org",
"@graph": [
{
"@type": "WebPage",
"@id": "https://www.example.com/cabins/spruce-cove/#webpage",
"url": "https://www.example.com/cabins/spruce-cove/",
"name": "Spruce Cove Cabin | Harbor & Pine Cabins",
"isPartOf": {
"@id": "https://www.example.com/#website"
},
"publisher": {
"@id": "https://www.example.com/#organization"
},
"breadcrumb": {
"@id": "https://www.example.com/cabins/spruce-cove/#breadcrumb"
},
"mainEntity": {
"@id": "https://www.example.com/cabins/spruce-cove/#rental"
}
},
{
"@type": "BreadcrumbList",
"@id": "https://www.example.com/cabins/spruce-cove/#breadcrumb",
"itemListElement": [
{
"@type": "ListItem",
"position": 1,
"name": "Home",
"item": "https://www.example.com/"
},
{
"@type": "ListItem",
"position": 2,
"name": "Cabins",
"item": "https://www.example.com/cabins/"
},
{
"@type": "ListItem",
"position": 3,
"name": "Spruce Cove Cabin",
"item": "https://www.example.com/cabins/spruce-cove/"
}
]
},
{
"@type": "VacationRental",
"@id": "https://www.example.com/cabins/spruce-cove/#rental",
"additionalType": "Cabin",
"name": "Spruce Cove Cabin",
"identifier": "HPC-0412",
"url": "https://www.example.com/cabins/spruce-cove/",
"description": "Two-bedroom cabin on Moosehead Lake with a wood stove, a dock and a screened porch.",
"brand": {
"@type": "Brand",
"name": "harbor-and-pine-cabins"
},
"image": [
"https://www.example.com/img/cabins/spruce-cove/exterior.jpg",
"https://www.example.com/img/cabins/spruce-cove/living-room.jpg",
"https://www.example.com/img/cabins/spruce-cove/kitchen.jpg",
"https://www.example.com/img/cabins/spruce-cove/bedroom-1.jpg",
"https://www.example.com/img/cabins/spruce-cove/bedroom-2.jpg",
"https://www.example.com/img/cabins/spruce-cove/bathroom.jpg",
"https://www.example.com/img/cabins/spruce-cove/porch.jpg",
"https://www.example.com/img/cabins/spruce-cove/dock.jpg"
],
"latitude": 45.46012,
"longitude": -69.59147,
"address": {
"@type": "PostalAddress",
"streetAddress": "41 Cove Road",
"addressLocality": "Greenville",
"addressRegion": "ME",
"postalCode": "04441",
"addressCountry": "US"
},
"checkinTime": "16:00:00-05:00",
"checkoutTime": "10:00:00-05:00",
"knowsLanguage": [
"en-US",
"fr-CA"
],
"containsPlace": {
"@type": "Accommodation",
"additionalType": "EntirePlace",
"occupancy": {
"@type": "QuantitativeValue",
"value": 5
},
"numberOfBedrooms": 2,
"numberOfBathroomsTotal": 1.5,
"numberOfRooms": 5,
"floorSize": {
"@type": "QuantitativeValue",
"value": 1150,
"unitCode": "FTK"
},
"bed": [
{
"@type": "BedDetails",
"numberOfBeds": 1,
"typeOfBed": "Queen"
},
{
"@type": "BedDetails",
"numberOfBeds": 2,
"typeOfBed": "Single"
}
],
"amenityFeature": [
{
"@type": "LocationFeatureSpecification",
"name": "wifi",
"value": true
},
{
"@type": "LocationFeatureSpecification",
"name": "kitchen",
"value": true
},
{
"@type": "LocationFeatureSpecification",
"name": "fireplace",
"value": true
},
{
"@type": "LocationFeatureSpecification",
"name": "petsAllowed",
"value": false
},
{
"@type": "LocationFeatureSpecification",
"name": "parkingType",
"value": "Free"
},
{
"@type": "LocationFeatureSpecification",
"name": "licenseNum",
"value": "Greenville STR-2026-118"
}
]
},
"aggregateRating": {
"@type": "AggregateRating",
"ratingValue": 4.9,
"bestRating": 5,
"worstRating": 1,
"ratingCount": 86
},
"review": [
{
"@type": "Review",
"author": {
"@type": "Person",
"name": "Priya Raman"
},
"reviewRating": {
"@type": "Rating",
"ratingValue": 5,
"bestRating": 5,
"worstRating": 1
},
"datePublished": "2026-08-02",
"contentReferenceTime": "2026-07-24"
}
]
}
]
}
The Logic As A Flowchart
The same logic as the builder above, drawn for readers who do not write code. Every Yes moves down. A No that runs out to the line on the right stops everything, and no schema is output. Where the path splits, exactly one branch is taken. Each step was run against the builder itself before this page was published: 33 test cases, all passing.
-
A page for one place to stay
-
1Site has an https URL?the home page addressNo: no schemaYes
-
2Page has an https URL?the address of this pageNo: no schemaYes
-
3Rental has a name and a listing ID?the ID is the one in the Hotel Center feedNo: no schemaYes
-
4Eight or more photos with an https link?photos of the property itselfNo: no schemaYes
-
5Photos show a bedroom, a bathroom and a common area?at least one of eachNo: no schemaYes
-
6Map position to five decimal places?for example 45.46012 and -69.59147No: no schemaYes
-
7Says how many guests it sleeps?a whole number of one or moreNo: no schemaYes
-
Two or more breadcrumbs with a name and an https link?the trail shown on the pageYesA BreadcrumbList is added and linked from the pageNoNo BreadcrumbList
-
Build the linked nodesWebPage and VacationRental, with the one Accommodation it holds. Anything optional that is missing or invalid is left out
-
Output WebPage and VacationRentalNo schema
Validation
The output above was run through the SchemaCDN validator, which checks every rule in Google's documentation for each feature. It was validated together with the homepage graph, so the @id links resolve. Result: no errors, and eligible for:
Left Out On Purpose
- Prices and availability. Google takes those from the Hotel Center feed, not from the page.
- Amenities that are not on Google's list. The sample has a sauna, which is dropped.
- Reviews without the date they were written. The sample has one, which is dropped.
Implementation Checklist
- Show eight or more photos, with a bedroom, a bathroom and a common area among them.
- Give the map position to five decimal places. A rounded one is rejected.
- Use the same listing ID as the Hotel Center feed, and keep it stable.
- State how many guests the place sleeps, as a whole number.
- Write amenity names exactly as Google lists them, in English.