Blog · Website fixes
LocalBusiness schema in plain English (with a copy-ready example)
What LocalBusiness structured data is, what it can and can't do for AI answers, a correct example, and how to add it on WordPress, Wix, Squarespace and Shopify.
· 6 min read
"Add schema markup" is one of the most common pieces of advice for appearing in AI answers and in Google. It's also one of the least explained. This article covers what it is, what it does and doesn't do, a correct example you can adapt, and how to add it on the four website builders most small businesses use.
What it is
Schema markup (also called structured data) is a short block of code on your web page that states facts about your business in a fixed format that software can read without guessing. Visitors never see it. It sits in the page's code and says, in effect: this is a plumber, called this, at this address, with this phone number, open these hours.
The vocabulary comes from schema.org (external site), a shared standard backed by the major search engines. LocalBusiness is the general type for a business with a physical location or service area, and it has more specific types underneath it, such as Plumber, Dentist, Restaurant or HairSalon. Google's LocalBusiness documentation (external site) asks you to use the most specific type that fits.
The usual format is JSON-LD: a small block of text inside a <script> tag. It's the format all four builders below accept.
What it can and can't do
It's worth being honest here, because schema is often oversold.
It can make the basic facts about your business unambiguous. A web page might mention three phone numbers and two addresses; your schema says which one is the business's. Any system that reads it, whether a search engine, an AI crawler or a listing site, gets your name, address, phone number and hours without having to interpret the page.
It can't make an AI assistant recommend you. Google says plainly, in its guide to AI features (external site), that there is no special schema.org structured data needed to appear in AI Overviews or AI Mode. OpenAI and Perplexity haven't said whether or how they use it. Schema is good hygiene that removes doubt about your facts. It is not a ranking switch.
One rule matters more than the rest: everything in your schema must also be visible on the page. Google's AI search guidance (external site) repeats this. Don't put a service area, rating or opening hours in the code that a visitor can't see on the page itself.
A correct example
Here is a complete example for an invented plumbing business in Leeds. The phone number is from a range Ofcom reserves for fiction, and the domain ends in .example, which is reserved and never used by a real site. Replace every value with your own.
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Plumber",
"name": "Harbour Plumbing and Heating",
"url": "https://www.harbourplumbing.example/",
"telephone": "+44 113 496 0123",
"address": {
"@type": "PostalAddress",
"streetAddress": "12 Canal Wharf Road",
"addressLocality": "Leeds",
"postalCode": "LS1 4AA",
"addressCountry": "GB"
},
"geo": {
"@type": "GeoCoordinates",
"latitude": 53.79486,
"longitude": -1.54762
},
"openingHoursSpecification": [
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday"],
"opens": "08:00",
"closes": "18:00"
},
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": "Saturday",
"opens": "09:00",
"closes": "13:00"
}
],
"areaServed": ["Leeds", "Headingley", "Horsforth"]
}
</script>
What each part means:
@type: the most specific type that fits. Browse the types listed on schema.org's LocalBusiness page (external site). Some types have changed: schema.org now marksAttorneyas deprecated and recommendsLegalServiceinstead.name: your business name exactly as it appears on your sign, your Google Business Profile and your listings. Not a name with keywords stuffed in.url: the page for this location. If you have several locations, each location page gets its own block.telephone: in international format, with country and area code, as Google recommends.address: the required part. If you work from home and don't show your address publicly, leavestreetAddressout and keep the town and postcode area you're happy to show.geo: your coordinates. Google asks for at least five decimal places. You can copy them from Google Maps by right-clicking your location.openingHoursSpecification: one entry per group of days with the same hours, in 24-hour time. Leave out days you're closed.areaServed: the towns you cover. Useful for trades that travel to customers; make sure the same towns are named on the page.
If you have accounts on Facebook, Instagram or a major listing site, you can add a sameAs list containing those profile URLs. It tells readers that those profiles are the same business.
Before you publish, paste the block into the Schema Markup Validator (external site) to check it's valid, and into Google's Rich Results Test (external site) to see how Google reads it. Both are free.
How to add it
The block goes into the page's <head>, or anywhere in the page. Put it on your homepage, and on each location page if you have more than one.
WordPress
Check first whether your theme or SEO plugin already outputs business schema; many SEO plugins add some by default. Two blocks that disagree are worse than one. If nothing is there, a header-and-footer plugin is the simplest route: WPCode (external site), for example, has a "Header" box for code that goes on every page. Paste the whole block, including the <script> tags, and save.
Wix
Wix accepts JSON-LD per page. Its help article, Adding structured data markup to your site's pages (external site), walks through it: open the page's SEO settings, choose to add new markup under Structured Data Markup, give it a name and paste your JSON-LD. Paste only the part between the curly brackets, without the <script> tags, since Wix wraps it for you. Wix limits each block to 7,000 characters and five blocks per page.
Squarespace
Use code injection. Squarespace's guide, Using code injection (external site), explains both options: the site-wide Header field adds code to every page, and each page's Advanced settings has a Page Header Code Injection field for that page only. Use the page-level field on your homepage or location page. Code injection is available on the Core, Plus and Advanced plans and some older plans.
Shopify
Shopify's theme code editor (external site) is under Online Store, then the "…" menu beside your theme, then Edit code. Open theme.liquid in the Layout folder and paste the block just before the closing </head> tag. Duplicate your theme first so you can roll back. Many Shopify themes already output Organization schema; a LocalBusiness block for your shop's physical location sits alongside it.
After you've added it
Re-run the validator against your live page, not just the pasted code, to confirm it's actually there. Then check that the same name, address, phone number and hours appear on your Google Business Profile and your main listings. Schema is one copy of your facts; it only removes doubt if every other copy agrees with it.
How Saymeter handles this
When Saymeter reads your website and finds missing or mismatched LocalBusiness schema, it writes the block for you from your real details, with paste steps for your website builder, then re-reads your page to confirm it went live. It's one of the fix types described on our methodology page. A free scan shows where you stand in AI answers before you change anything.