JAVASCRIPTseobeginner
Add Schema Markup to Weebly Website
Implement Schema.org structured data on Weebly using Embed Code
Faisal Yaqoob
November 28, 2025
#weebly#schema#seo#structured-data#json-ld
Code
javascript
1 // Add using Embed Code element in header or footer 2 <script type="application/ld+json"> 3 { 4 "@context": "https://schema.org", 5 "@type": "Organization", 6 "name": "Your Business Name", 7 "url": "https://yoursite.weebly.com", 8 "logo": "https://cdn2.editmysite.com/images/your-logo.png", 9 "description": "Your business description", 10 "telephone": "+1-555-123-4567", 11 "email": "info@yourbusiness.com", 12 "address": { 13 "@type": "PostalAddress", 14 "streetAddress": "123 Business Lane", 15 "addressLocality": "Austin", 16 "addressRegion": "TX", 17 "postalCode": "78701", 18 "addressCountry": "US" 19 }, 20 "sameAs": [ 21 "https://www.facebook.com/yourbusiness", 22 "https://www.twitter.com/yourbusiness", 23 "https://www.instagram.com/yourbusiness", 24 "https://www.linkedin.com/company/yourbusiness" 25 ] 26 } 27 </script>
Add Schema Markup to Weebly Website
Implement Schema.org structured data on your Weebly website to improve SEO and get rich snippets in Google search results.
Organization Schema (Site-wide)
// Add using Embed Code element in header or footer
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Organization",
"name": "Your Business Name",
"url": "https://yoursite.weebly.com",
"logo": "https://cdn2.editmysite.com/images/your-logo.png",
"description": "Your business description",
"telephone": "+1-555-123-4567",
"email": "info@yourbusiness.com",
"address": {
"@type": "PostalAddress",
"streetAddress": "123 Business Lane",
"addressLocality": "Austin",
"addressRegion": "TX",
"postalCode": "78701",
"addressCountry": "US"
},
"sameAs": [
"https://www.facebook.com/yourbusiness",
"https://www.twitter.com/yourbusiness",
"https://www.instagram.com/yourbusiness",
"https://www.linkedin.com/company/yourbusiness"
]
}
</script>
LocalBusiness Schema
// Add to header or specific page using Embed Code element
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "LocalBusiness",
"name": "Your Local Business",
"description": "Brief description of your local business",
"image": "https://cdn2.editmysite.com/images/business.jpg",
"address": {
"@type": "PostalAddress",
"streetAddress": "456 Main Street",
"addressLocality": "Seattle",
"addressRegion": "WA",
"postalCode": "98101",
"addressCountry": "US"
},
"geo": {
"@type": "GeoCoordinates",
"latitude": "47.6062",
"longitude": "-122.3321"
},
"telephone": "+1-206-555-0100",
"email": "contact@yourbusiness.com",
"url": "https://yoursite.weebly.com",
"openingHoursSpecification": [
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday"],
"opens": "08:00",
"closes": "18:00"
},
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": ["Saturday"],
"opens": "09:00",
"closes": "15:00"
}
],
"priceRange": "$$"
}
</script>
Product Schema for E-commerce
// Add to product page using Embed Code element
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Product",
"name": "Product Name",
"description": "Detailed description of your product",
"image": [
"https://cdn2.editmysite.com/images/product-1.jpg",
"https://cdn2.editmysite.com/images/product-2.jpg"
],
"brand": {
"@type": "Brand",
"name": "Brand Name"
},
"sku": "PROD-ABC-123",
"offers": {
"@type": "Offer",
"url": "https://yoursite.weebly.com/store/p1/Product-Name",
"priceCurrency": "USD",
"price": "39.99",
"availability": "https://schema.org/InStock",
"priceValidUntil": "2026-12-31",
"seller": {
"@type": "Organization",
"name": "Your Store Name"
}
},
"aggregateRating": {
"@type": "AggregateRating",
"ratingValue": "4.6",
"reviewCount": "58"
},
"review": [
{
"@type": "Review",
"author": {
"@type": "Person",
"name": "Customer Name"
},
"datePublished": "2025-11-15",
"reviewRating": {
"@type": "Rating",
"ratingValue": "5"
},
"reviewBody": "Great product! Highly recommended."
}
]
}
</script>
Article Schema for Blog Posts
// Add to blog post page using Embed Code element
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "BlogPosting",
"headline": "Your Blog Post Title",
"description": "Brief description of your blog post",
"image": "https://cdn2.editmysite.com/images/blog-post.jpg",
"author": {
"@type": "Person",
"name": "Author Name",
"url": "https://yoursite.weebly.com/about"
},
"publisher": {
"@type": "Organization",
"name": "Your Website Name",
"logo": {
"@type": "ImageObject",
"url": "https://cdn2.editmysite.com/images/logo.png"
}
},
"datePublished": "2025-11-28",
"dateModified": "2025-11-28",
"mainEntityOfPage": {
"@type": "WebPage",
"@id": "https://yoursite.weebly.com/blog/post-title"
}
}
</script>
FAQ Schema
// Add to FAQ page using Embed Code element
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "FAQPage",
"mainEntity": [
{
"@type": "Question",
"name": "How do I place an order?",
"acceptedAnswer": {
"@type": "Answer",
"text": "You can place an order by browsing our products, adding items to your cart, and proceeding to checkout. We accept all major credit cards and PayPal."
}
},
{
"@type": "Question",
"name": "What is your return policy?",
"acceptedAnswer": {
"@type": "Answer",
"text": "We offer a 30-day money-back guarantee. If you're not satisfied with your purchase, you can return it within 30 days for a full refund."
}
},
{
"@type": "Question",
"name": "Do you ship internationally?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Yes, we ship to over 100 countries worldwide. International shipping rates vary by location and are calculated at checkout."
}
},
{
"@type": "Question",
"name": "How can I contact customer support?",
"acceptedAnswer": {
"@type": "Answer",
"text": "You can contact our customer support team via email at support@yourbusiness.com or call us at +1-555-123-4567 during business hours."
}
}
]
}
</script>
Service Schema
// Add to services page using Embed Code element
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Service",
"serviceType": "Web Design Services",
"provider": {
"@type": "Organization",
"name": "Your Business Name",
"url": "https://yoursite.weebly.com"
},
"areaServed": {
"@type": "State",
"name": "California"
},
"hasOfferCatalog": {
"@type": "OfferCatalog",
"name": "Web Design Services",
"itemListElement": [
{
"@type": "Offer",
"itemOffered": {
"@type": "Service",
"name": "Custom Website Design",
"description": "Professional custom website design tailored to your brand"
}
},
{
"@type": "Offer",
"itemOffered": {
"@type": "Service",
"name": "E-commerce Development",
"description": "Full-featured online store development"
}
}
]
}
}
</script>
Restaurant Schema
// Add to restaurant site using Embed Code element
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Restaurant",
"name": "Your Restaurant Name",
"description": "Description of your restaurant",
"image": "https://cdn2.editmysite.com/images/restaurant.jpg",
"address": {
"@type": "PostalAddress",
"streetAddress": "789 Food Street",
"addressLocality": "Miami",
"addressRegion": "FL",
"postalCode": "33101",
"addressCountry": "US"
},
"geo": {
"@type": "GeoCoordinates",
"latitude": "25.7617",
"longitude": "-80.1918"
},
"telephone": "+1-305-555-0200",
"url": "https://yourrestaurant.weebly.com",
"servesCuisine": ["Italian", "American"],
"priceRange": "$$$",
"openingHoursSpecification": [
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": ["Monday", "Tuesday", "Wednesday", "Thursday"],
"opens": "11:00",
"closes": "22:00"
},
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": ["Friday", "Saturday"],
"opens": "11:00",
"closes": "23:00"
},
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": "Sunday",
"opens": "12:00",
"closes": "21:00"
}
],
"acceptsReservations": "True",
"menu": "https://yourrestaurant.weebly.com/menu"
}
</script>
How to Add Embed Code in Weebly
Method 1: Header/Footer (Site-wide)
- Access Theme Settings
- Go to Theme > Edit HTML/CSS
- Or use Settings > SEO for header code
- Add to Header
- Locate
<head>section - Paste your schema code before
</head> - Click Save
- Publish
- Click Publish to make changes live
Method 2: Embed Code Element (Page-specific)
- Edit Page
- Click on the page you want to edit
- Enter edit mode
- Add Embed Code Element
- Drag Embed Code element from left panel
- Drop it where you want it (usually at top or bottom)
- Click Edit Custom HTML
- Click "Edit Custom HTML" button
- Paste your schema code
- Save and Publish
- Click outside the element
- Publish your site
Method 3: Using Header Code (SEO Settings)
- Access SEO Settings
- Go to Settings > SEO
- Header Code
- Scroll to Header Code section
- Paste your schema code
- Save
- Click Save
- Changes apply site-wide
Dynamic Schema with JavaScript
// Add using Embed Code element
<script>
document.addEventListener('DOMContentLoaded', function() {
// Get page data
var pageTitle = document.title;
var metaDesc = document.querySelector('meta[name="description"]');
var description = metaDesc ? metaDesc.content : '';
var currentUrl = window.location.href;
// Check if it's a blog post (Weebly blog posts have .blog-post class)
if (document.querySelector('.blog-post')) {
var postTitle = document.querySelector('.blog-title h2')
? document.querySelector('.blog-title h2').textContent
: pageTitle;
var dateElem = document.querySelector('.blog-date');
var publishDate = dateElem ? dateElem.getAttribute('datetime') : new Date().toISOString();
var schema = {
"@context": "https://schema.org",
"@type": "BlogPosting",
"headline": postTitle,
"description": description,
"datePublished": publishDate,
"author": {
"@type": "Person",
"name": "Your Name"
},
"publisher": {
"@type": "Organization",
"name": "Your Site Name",
"logo": {
"@type": "ImageObject",
"url": "https://cdn2.editmysite.com/images/logo.png"
}
},
"mainEntityOfPage": {
"@type": "WebPage",
"@id": currentUrl
}
};
// Inject schema
var script = document.createElement('script');
script.type = 'application/ld+json';
script.text = JSON.stringify(schema, null, 2);
document.head.appendChild(script);
}
});
</script>
Breadcrumb Schema for Navigation
// Add to pages with breadcrumb navigation
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "BreadcrumbList",
"itemListElement": [
{
"@type": "ListItem",
"position": 1,
"name": "Home",
"item": "https://yoursite.weebly.com"
},
{
"@type": "ListItem",
"position": 2,
"name": "Products",
"item": "https://yoursite.weebly.com/products"
},
{
"@type": "ListItem",
"position": 3,
"name": "Product Name",
"item": "https://yoursite.weebly.com/products/product-name"
}
]
}
</script>
Video Schema
// Add to pages with video content
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "VideoObject",
"name": "Video Title",
"description": "Video description",
"thumbnailUrl": "https://cdn2.editmysite.com/images/video-thumb.jpg",
"uploadDate": "2025-11-28",
"duration": "PT5M30S",
"contentUrl": "https://yoursite.weebly.com/video.mp4",
"embedUrl": "https://www.youtube.com/embed/VIDEO_ID"
}
</script>
Testing Your Schema
- Google Rich Results Test
- Visit: https://search.google.com/test/rich-results
- Enter your Weebly page URL
- Check for validation errors
- Schema Validator
- Visit: https://validator.schema.org/
- Validate your markup
- View Page Source
- Right-click page > "View Page Source"
- Search for "application/ld+json"
- Verify schema appears
Common Weebly Selectors
// Useful selectors for Weebly pages
'.blog-post' // Blog post container
'.blog-title h2' // Blog post title
'.blog-date' // Blog post date
'.blog-author' // Blog post author
'.product-title' // Product name
'.product-price' // Product price
'h1' // Page heading
document.title // Page title
Best Practices for Weebly
- Use Embed Code element: Most flexible method
- Header for site-wide: Use header code for Organization schema
- Page-specific for content: Use Embed Code for products, blog posts
- Absolute URLs: Always use full https:// URLs
- Test after publishing: Schema may not appear in preview mode
- Keep it updated: Update schema when content changes
- Don't overdo it: Only mark up visible content
- Validate before going live: Use testing tools
Weebly Plan Requirements
- Free Plan: Can add schema using Embed Code element
- Starter/Pro/Business: Full access to all methods including header code
- All Plans: Schema markup works on all Weebly plans
Troubleshooting
Schema not appearing:
- Check if code is published (not just saved)
- Verify Embed Code element is visible (not hidden)
- Check browser console for JavaScript errors
Invalid schema:
- Use JSON validator to check syntax
- Ensure all quotes are properly escaped
- Check that required fields are present
Not showing in search:
- Give Google time to crawl (2-4 weeks)
- Submit sitemap in Google Search Console
- Verify schema is valid with testing tools
Features
- Easy Implementation: Simple drag-and-drop Embed Code
- All Plans Supported: Works on free and paid Weebly plans
- Flexible Placement: Site-wide or page-specific
- E-commerce Ready: Product schemas for Weebly stores
- Blog Optimized: Article schemas for blog posts
- Local SEO: LocalBusiness and Restaurant schemas
- Dynamic Support: JavaScript for auto-generated schema
- SEO Boost: Improve search engine visibility
Related Snippets
Add Schema Markup to Squarespace Website
Implement Schema.org structured data on Squarespace using Code Injection
JAVASCRIPTseobeginner
javascriptPreview
// Add to Settings > Advanced > Code Injection > Header
<script type="application/ld+json">
{
"@context": "https://schema.org",
...#squarespace#schema#seo+2
11/28/2025
View
Add Schema Markup to Webflow Website
Implement Schema.org structured data in Webflow using Custom Code
JAVASCRIPTseobeginner
javascriptPreview
// Add to Page Settings > Custom Code > Head Code
<script type="application/ld+json">
{
"@context": "https://schema.org",
...#webflow#schema#seo+3
11/28/2025
View
Add Schema Markup to Wix Website
Implement Schema.org structured data on Wix sites using Custom Code
JAVASCRIPTseobeginner
javascriptPreview
// Add to Custom Code in Wix (Settings > Custom Code)
<script type="application/ld+json">
{
"@context": "https://schema.org",
...#wix#schema#seo+2
11/28/2025
View