Free tool

Schema markup for a local business

Fill in your business details and the tool builds LocalBusiness JSON-LD as you type, ready to add to your website. It all runs in your browser and nothing is sent anywhere.

Opening hours

Use the 24-hour format 8:00-17:00. Write a lunch break as 8:00-12:00, 13:00-17:00. An empty field means closed, and the word 24h means open all day.

    
        

    How to use it

    1. Fill in the name, business type and address. Choose the most specific type you can, for example Hair salon instead of the general local business.
    2. Add the phone number, website and opening hours exactly as they appear on your website and in your Google Business Profile.
    3. Copy the code with the Copy code button and paste it into the HTML of your page, ideally in the head section.
    4. Test it in Google's Rich Results Test, where you can enter the page address or paste the code.

    What LocalBusiness structured data is

    Structured data is a short piece of code in a page that visitors do not see. It tells search engines, in a fixed format, what a person would read from the text: what the business is called, what it does, where it is, its phone number and when it is open. The most common format is JSON-LD, which Google also recommends, and the vocabulary of types and properties is maintained by the schema.org project.

    The LocalBusiness type and its subtypes, such as Restaurant, HairSalon or Plumber, are meant for businesses with a premises or an area where they serve customers. Google's documentation recommends using the most specific subtype. For a longer introduction, see Local business schema.

    Which details to fill in

    According to Google's documentation, a local business needs only two properties: the name and the address. A phone number, website, opening hours, coordinates and price range are recommended. Write the phone number with the country code, for example +44 or +1, as Google recommends.

    The profiles field is for links to your business on Facebook, Instagram or in business directories. In the code they are written as sameAs, and they help tie the different mentions of your business together. List only profiles that really belong to your business.

    The most important rule: the details in the code must match what is visible on the page, in your Google Business Profile and in directories. If your website shows different opening hours than Google does, no code will fix that mismatch. Why matching details matter is explained in Local SEO for small business. For how to manage hours around holidays, see Holiday hours in your Google Business Profile.

    What structured data brings and what it does not

    Google says that when someone searches for a specific business, its details can contribute to what appears in the business information panel. It does not promise a display or a better ranking, though. Structured data is tidy groundwork: search engines and other systems that read the web get your business details in an unambiguous form and do not have to guess them from the text.

    Always test the code after you paste it. The Rich Results Test shows whether Google can read it, and the schema.org validator checks the whole markup. The free website check also tells you whether your homepage already has structured data and whether it is error-free.

    Frequently asked questions

    Where do I put the generated code?

    Paste the whole block, including the script tags, into the HTML of your page, ideally in the head section of your homepage or contact page. In WordPress you can do this with a custom code field in your theme or with a plugin that inserts code into the header. If someone else manages your site, send them the code and ask them to add it.

    Which details are required?

    According to Google's documentation for local businesses, the name and the address are required. It also recommends adding a phone number with the country code, a website, opening hours, coordinates and a price range. Fill in only what is true and also visible on the page.

    Does structured data guarantee a better place in Google?

    No. Structured data helps search engines understand who you are, where you are and when you are open, but it does not decide your ranking. That also depends on your content, reviews, Business Profile and competitors. Google does not promise a rich result either, even when the markup is correct.

    Should I list the days when I am closed?

    You do not have to. The generator only writes the days that have opening hours and treats every other day as closed. Handle holidays and one-off exceptions in your Google Business Profile instead, where you can set special opening hours for specific dates.

    Check your whole website

    The website check finds out whether your homepage has structured data, a title, a description and access for search and AI crawlers. Free, no signup.

    Run the website check