JAVASCRIPTseobeginner
Add Schema Markup to Webflow Website
Implement Schema.org structured data in Webflow using Custom Code
Faisal Yaqoob
November 28, 2025
#webflow#schema#seo#structured-data#json-ld#cms
Code
javascript
1 // Add to Page Settings > Custom Code > Head Code 2 <script type="application/ld+json"> 3 { 4 "@context": "https://schema.org", 5 "@type": "Article", 6 "headline": "Your Article Title", 7 "description": "Brief description of your article", 8 "image": "https://uploads-ssl.webflow.com/your-image.jpg", 9 "author": { 10 "@type": "Person", 11 "name": "Author Name" 12 }, 13 "publisher": { 14 "@type": "Organization", 15 "name": "Your Site Name", 16 "logo": { 17 "@type": "ImageObject", 18 "url": "https://uploads-ssl.webflow.com/logo.png" 19 } 20 }, 21 "datePublished": "2025-11-28", 22 "dateModified": "2025-11-28" 23 } 24 </script>
Add Schema Markup to Webflow Website
Implement Schema.org structured data on your Webflow website to improve SEO and get rich snippets in search results.
Article Schema for Blog Posts
// Add to Page Settings > Custom Code > Head Code
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Article",
"headline": "Your Article Title",
"description": "Brief description of your article",
"image": "https://uploads-ssl.webflow.com/your-image.jpg",
"author": {
"@type": "Person",
"name": "Author Name"
},
"publisher": {
"@type": "Organization",
"name": "Your Site Name",
"logo": {
"@type": "ImageObject",
"url": "https://uploads-ssl.webflow.com/logo.png"
}
},
"datePublished": "2025-11-28",
"dateModified": "2025-11-28"
}
</script>
Dynamic Blog Post Schema with CMS
<!-- Add to Collection Template Page Settings > Head Code -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "BlogPosting",
"headline": "{{wf {"path":"name","type":"PlainText"\} }}",
"description": "{{wf {"path":"post-summary","type":"PlainText"\} }}",
"image": "{{wf {"path":"main-image:url","type":"ImageRef"\} }}",
"author": {
"@type": "Person",
"name": "{{wf {"path":"author:name","type":"PlainText"\} }}"
},
"publisher": {
"@type": "Organization",
"name": "Your Site Name",
"logo": {
"@type": "ImageObject",
"url": "https://uploads-ssl.webflow.com/logo.png"
}
},
"datePublished": "{{wf {"path":"created-on","type":"Date"\} }}",
"dateModified": "{{wf {"path":"updated-on","type":"Date"\} }}"
}
</script>
LocalBusiness Schema
// Add to Site Settings > Custom Code > Head Code
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "LocalBusiness",
"name": "Your Business Name",
"description": "Brief description of your business",
"image": "https://uploads-ssl.webflow.com/business.jpg",
"address": {
"@type": "PostalAddress",
"streetAddress": "123 Main Street",
"addressLocality": "San Francisco",
"addressRegion": "CA",
"postalCode": "94102",
"addressCountry": "US"
},
"geo": {
"@type": "GeoCoordinates",
"latitude": "37.7749",
"longitude": "-122.4194"
},
"telephone": "+1-415-555-0100",
"email": "info@yourbusiness.com",
"url": "https://yoursite.webflow.io",
"openingHoursSpecification": [
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday"],
"opens": "09:00",
"closes": "18:00"
},
{
"@type": "OpeningHoursSpecification",
"dayOfWeek": "Saturday",
"opens": "10:00",
"closes": "16:00"
}
],
"priceRange": "$$",
"aggregateRating": {
"@type": "AggregateRating",
"ratingValue": "4.8",
"reviewCount": "156"
}
}
</script>
E-commerce Product Schema
// Add to Product Template Page > Custom Code > Head
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Product",
"name": "Product Name",
"description": "Detailed product description",
"image": [
"https://uploads-ssl.webflow.com/product-1.jpg",
"https://uploads-ssl.webflow.com/product-2.jpg"
],
"brand": {
"@type": "Brand",
"name": "Brand Name"
},
"sku": "PROD-123-456",
"offers": {
"@type": "Offer",
"url": "https://yoursite.webflow.io/products/product-name",
"priceCurrency": "USD",
"price": "99.99",
"availability": "https://schema.org/InStock",
"priceValidUntil": "2026-12-31",
"seller": {
"@type": "Organization",
"name": "Your Store Name"
}
},
"aggregateRating": {
"@type": "AggregateRating",
"ratingValue": "4.7",
"reviewCount": "89"
}
}
</script>
Dynamic E-commerce Product with CMS
<!-- Product Collection Template > Custom Code > Head -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Product",
"name": "{{wf {"path":"name","type":"PlainText"\} }}",
"description": "{{wf {"path":"description","type":"PlainText"\} }}",
"image": "{{wf {"path":"main-image:url","type":"ImageRef"\} }}",
"brand": {
"@type": "Brand",
"name": "{{wf {"path":"brand","type":"PlainText"\} }}"
},
"sku": "{{wf {"path":"sku","type":"PlainText"\} }}",
"offers": {
"@type": "Offer",
"priceCurrency": "USD",
"price": "{{wf {"path":"price","type":"Number"\} }}",
"availability": "https://schema.org/InStock"
}
}
</script>
FAQ Schema
// Add to FAQ page > Custom Code > Head
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "FAQPage",
"mainEntity": [
{
"@type": "Question",
"name": "How do I get started with Webflow?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Getting started with Webflow is easy. Simply sign up for a free account, choose a template or start from scratch, and use the visual designer to build your website."
}
},
{
"@type": "Question",
"name": "Does Webflow offer e-commerce features?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Yes, Webflow offers comprehensive e-commerce features including product management, cart functionality, checkout, and payment processing."
}
},
{
"@type": "Question",
"name": "Can I use custom code in Webflow?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Yes, Webflow allows you to add custom HTML, CSS, and JavaScript code to enhance your website's functionality."
}
}
]
}
</script>
Organization Schema (Site-wide)
// Add to Site Settings > Custom Code > Head Code
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Organization",
"name": "Your Company Name",
"url": "https://yoursite.webflow.io",
"logo": "https://uploads-ssl.webflow.com/logo.png",
"description": "Your company description",
"telephone": "+1-415-555-0100",
"email": "contact@yourcompany.com",
"address": {
"@type": "PostalAddress",
"streetAddress": "123 Market Street",
"addressLocality": "San Francisco",
"addressRegion": "CA",
"postalCode": "94102",
"addressCountry": "US"
},
"sameAs": [
"https://www.facebook.com/yourcompany",
"https://www.twitter.com/yourcompany",
"https://www.instagram.com/yourcompany",
"https://www.linkedin.com/company/yourcompany"
]
}
</script>
How to Add Custom Code in Webflow
For Site-wide Schema:
- Open Webflow Designer
- Navigate to your project
- Click the gear icon (Settings)
- Access Custom Code
- Go to "Custom Code" tab
- Locate "Head Code" section
- Add Schema
- Paste your schema code
- Click "Save Changes"
- Publish Site
- Click "Publish" to make changes live
For Page-specific Schema:
- Select Page
- Click "Pages" panel
- Select the page you want to add schema to
- Page Settings
- Click the gear icon next to the page name
- Go to "Custom Code" section
- Add to Head
- Paste schema in "Head Code"
- Click "Save"
- Publish
- Publish the site
For CMS Collection Templates:
- Open Collection Template
- Navigate to "CMS" panel
- Select your collection
- Open the template page
- Template Settings
- Click page settings gear icon
- Go to "Custom Code" tab
- Add Dynamic Fields
- Use CMS field references (see examples above)
- Click "Save"
- Publish
- Publish to apply to all collection items
Using Webflow CMS Fields in Schema
CMS Field Reference Format:
{{wf {"path":"field-slug","type":"PlainText"} }}
Common Field Types:
- PlainText: For text fields
- Date: For date fields
- Number: For number fields
- ImageRef: For image URLs (use with
:url)
Example: Dynamic Author Info
"author": {
"@type": "Person",
"name": "{{wf {"path":"author:name","type":"PlainText"\} }}",
"url": "{{wf {"path":"author:slug","type":"PlainText"\} }}"
}
Advanced: JavaScript Schema Generator
// Add to Page Settings > Custom Code > Before </body> tag
<script>
document.addEventListener('DOMContentLoaded', function() {
// Get page data
const title = document.querySelector('h1')?.textContent;
const description = document.querySelector('meta[name="description"]')?.content;
const image = document.querySelector('meta[property="og:image"]')?.content;
// Create schema
const schema = {
"@context": "https://schema.org",
"@type": "WebPage",
"name": title,
"description": description,
"image": image,
"url": window.location.href
};
// Inject schema
const script = document.createElement('script');
script.type = 'application/ld+json';
script.text = JSON.stringify(schema);
document.head.appendChild(script);
});
</script>
Testing Your Schema
- Google Rich Results Test
- Visit: https://search.google.com/test/rich-results
- Enter your Webflow page URL
- Fix any errors
- Schema Validator
- Visit: https://validator.schema.org/
- Validate your markup
- Webflow Preview
- Use "View Source" to confirm schema appears
- Check in published site, not just preview
Best Practices
- Use CMS fields: Leverage Webflow CMS for dynamic schema
- Absolute URLs: Always use full URLs with https://
- Escape quotes: Use
"in CMS field references - Test thoroughly: Validate before publishing
- Site vs Page: Use site-wide for Organization, page-level for content
- Keep updated: Update schema when content changes
- Rich results: Monitor in Google Search Console
Common Issues & Solutions
Issue: Schema not appearing
- Solution: Ensure code is in Head, not Body
- Check that site is published, not just saved
Issue: CMS fields not working
- Solution: Use correct field slug
- Escape quotes properly:
"
Issue: Images not loading
- Solution: Use Webflow CDN URLs
- Format:
field-name:urlfor image fields
Features
- Visual Builder Compatible: Works with Webflow Designer
- CMS Integration: Dynamic schema for collections
- E-commerce Ready: Product schema for Webflow shops
- No Plugins Needed: Pure custom code implementation
- SEO Optimized: Improve search visibility
- Rich Snippets: Enable enhanced search results
- Flexible: Site-wide or page-specific schema
Related Snippets
SoftwareApplication Schema for Apps and Tools
Add SoftwareApplication structured data for apps, plugins, and SaaS tools to display ratings and pricing in Google
JAVASCRIPTseobeginner
javascriptPreview
const webAppSchema = {
"@context": "https://schema.org",
"@type": "WebApplication",
"name": "Schema Markup Generator",
...#software#app#schema+7
1/8/2026
View
HowTo Schema for Step-by-Step Guides
Add HowTo structured data for Google how-to rich results with steps, tools, materials, and estimated time
JAVASCRIPTseobeginner
javascriptPreview
const howToSchema = {
"@context": "https://schema.org",
"@type": "HowTo",
"name": "How to Set Up WordPress on a VPS Server",
...#howto#schema#seo+6
1/5/2026
View
Course Schema for Online Learning Platforms
Add Course structured data for Google course rich results with provider, duration, and pricing details
JAVASCRIPTseobeginner
javascriptPreview
const courseSchema = {
"@context": "https://schema.org",
"@type": "Course",
"name": "Complete WordPress Development Masterclass",
...#course#schema#seo+6
1/2/2026
View