Structured data tool

Local Business Schema Generator

Create LocalBusiness JSON-LD for a shop, restaurant, clinic or service business: type, address, coordinates, phone, opening hours and price range, in the format Google's structured data guidelines expect.

Right-click the entrance of your business in Google Maps to copy its coordinates, or use Where Am I if you are on site.

Opening hours

Google does not show stars for ratings a business publishes about itself. Only fill this in if the reviews are real and visible on the page.

Enter the business name to get started...

In short: LocalBusiness schema is structured data that states a business's name, type, address, phone number, coordinates and opening hours in a format search engines read without guessing. A local business schema generator builds that LocalBusiness JSON-LD block for you; paste it into the page that represents the location and test it with Google's Rich Results Test.

Which LocalBusiness properties Google reads

Google's local business documentation has only two required properties, but the recommended ones are where the value is. The more of them match your Google Business Profile, the easier it is for Google to tie the website and the listing together.

PropertyStatusFormat tip
nameRequiredReal-world name exactly as on signage and your profile, no keyword stuffing
addressRequiredA PostalAddress with as many sub-fields as apply
telephoneRecommendedInclude the country code: +1-555-010-0199, +44 20 7946 0000
geoRecommendedAt least 5 decimal places of latitude and longitude
openingHoursSpecificationRecommended24-hour hh:mm times, one entry per group of days
url, image, priceRangeRecommendedpriceRange under 100 characters, e.g. $$ or $10–25

Pick the most specific @type that fits. Dentist, Plumber or Bakery say more than the generic LocalBusiness, and every subtype inherits all the same properties, so nothing is lost.

Writing the address for any country

PostalAddress splits an address into parts that work worldwide. streetAddress holds the street, number and any unit. addressLocality is the city or town, addressRegion the state, province or county, postalCode the ZIP or postcode, and addressCountry a two-letter ISO 3166-1 code such as US, GB, DE or AU. Countries that don't use regions in postal addresses can skip addressRegion. What matters most is that the same address is written the same way on the page, in the schema and on your Business Profile; that name, address and phone consistency (NAP) is one of the basics of local SEO.

Service-area businesses that hide their address on Google, such as a mobile locksmith, should still include at least the city, region and country, and can add areaServed by hand to list the towns they cover.

Opening hours and geo coordinates in JSON-LD

The generator groups days with identical hours into one openingHoursSpecification entry, which keeps the code short. A shop open weekdays and Saturday mornings produces:

"openingHoursSpecification": [
  {"@type": "OpeningHoursSpecification",
   "dayOfWeek": ["Monday","Tuesday","Wednesday","Thursday","Friday"],
   "opens": "09:00", "closes": "17:00"},
  {"@type": "OpeningHoursSpecification",
   "dayOfWeek": "Saturday", "opens": "10:00", "closes": "14:00"}
]

Closed days are simply left out. For hours past midnight, such as a bar open 18:00 to 02:00, enter the closing time as it is; Google's documentation treats a closes earlier than opens as the next day. Holiday or seasonal hours go in a separate entry with validFrom and validThrough dates. For geo, use coordinates of the entrance rather than the middle of a large building or the city center, and keep them identical to the pin on your profile.

Placement, testing and what not to mark up

Put the script block on the page that best represents the location: the home page for a single-location business, a dedicated location page for each branch. It can sit in the <head> or the <body>. Run the URL through the Rich Results Test and the Schema Markup Validator at validator.schema.org; the first shows what Google can use, the second catches general schema.org errors. Avoid marking up details that are not true or not visible to users, such as hours the business doesn't keep or ratings you can't back with real reviews. Structured data that contradicts the page can lead to a manual action for spammy markup.

Frequently asked questions

Does LocalBusiness schema help you rank in the Google map pack?

Not directly. Map pack rankings come mainly from your Google Business Profile, proximity, reviews and prominence. The markup helps Google connect your website to that profile and confirms your name, address, phone and hours, which supports consistency rather than acting as a ranking boost.

Can I add star ratings to my own LocalBusiness schema?

You can add aggregateRating, but Google will not show stars for it. Since 2019 Google ignores self-serving reviews, meaning ratings a business publishes about itself on its own site through LocalBusiness or Organization markup. Only add a rating if it reflects real, visible reviews, and enter the true review count.

How do I mark up a business with several locations?

Give each location its own page with its own LocalBusiness block containing that branch's address, phone, coordinates and hours. Use a unique @id per location, for example the page URL plus #location. One sitewide block for the head office does not describe the branches.

How do I show that a business is open 24 hours?

Use an openingHoursSpecification with opens set to 00:00 and closes set to 23:59 for every day the business never closes. For a day it is closed, simply leave that day out.

Related tools: Local SERP Checker · Breadcrumb Schema Generator · FAQ Schema Generator