Bring Wine Knowledge to Your Website
Add clear, interactive wine cards to any page. One script tag, no extra dependencies, and flexible styling.
See how it worksSee it in action
These live cards use the same wine data as Wine Companion.
Quick start
Add two lines of HTML and the first card is ready.
<script type="module"
src="https://companion.decodewine.com/widget/wine-companion-widget.js">
</script>
<wine-card type="grape" random rotate-interval="10"></wine-card>Configuration
Tune the content, language, theme, and motion with HTML attributes or one global configuration.
| Attribute | Type | Default | Description |
|---|---|---|---|
type | string | "grape" | Card type: grape, blend, aroma, winemaking or country |
slug | string | — | Choose a specific item by slug |
random | boolean | false | Show a random item of the type |
difficulty | string | — | Filter by beginner, intermediate, or advanced |
locale | string | "en" | Language: en or de |
theme | string | "light" | Theme: light or dark |
rotate-interval | number | — | Rotate automatically after this many seconds |
transition | string | "flip" | flip, crossfade, slide, or scale-blur |
transition-duration | number | varies | Animation duration in milliseconds |
base-url | string | companion.decodewine.com | Data source URL |
opacity | number | 1 | Card opacity from 0 to 1; values below 1 add backdrop blur |
Global Configuration
Set defaults for all widgets on the page:
<script>
window.WineCompanionConfig = {
locale: 'de',
theme: 'dark',
transition: 'flip',
transitionDuration: 600,
opacity: 0.85
};
</script>Smooth transitions
Four built-in rotation animations. Pick the one that fits your site.
flip 3D Flip
Turn the card to reveal the next profile. This is the default.
crossfade Crossfade
Fade gently from one profile to the next.
slide Slide
Bring each new card in from below.
scale-blur Scale + Blur
Shrink, soften, then settle the next card into place.
Made for
Wine Blogs
Give readers a clear grape profile beside the story.
Wine Shops
Explain a bottle's grape varieties right on the product page.
Education
Add rotating grape cards to lessons and course pages.
Restaurants
Feature a wine or grape of the day on a digital menu.