tab-accordion
When the user wants to add or optimize tab or accordion components for content organization. Also use when the user mentions "tab component," "accordion," "expandable content," "collapsible sections," "tabbed content," "FAQ accordion," "how-to tabs," "horizontal tabs," "vertical accordion," "content in tabs," "hidden content SEO," "details summary," or "disclosure widget." For FAQ content, use faq-page-generator. For HowTo step sections (schema, placement), use howto-section-generator.
Best use case
tab-accordion is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
When the user wants to add or optimize tab or accordion components for content organization. Also use when the user mentions "tab component," "accordion," "expandable content," "collapsible sections," "tabbed content," "FAQ accordion," "how-to tabs," "horizontal tabs," "vertical accordion," "content in tabs," "hidden content SEO," "details summary," or "disclosure widget." For FAQ content, use faq-page-generator. For HowTo step sections (schema, placement), use howto-section-generator.
Teams using tab-accordion should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/tab-accordion/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How tab-accordion Compares
| Feature / Agent | tab-accordion | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
When the user wants to add or optimize tab or accordion components for content organization. Also use when the user mentions "tab component," "accordion," "expandable content," "collapsible sections," "tabbed content," "FAQ accordion," "how-to tabs," "horizontal tabs," "vertical accordion," "content in tabs," "hidden content SEO," "details summary," or "disclosure widget." For FAQ content, use faq-page-generator. For HowTo step sections (schema, placement), use howto-section-generator.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
AI Agents for Marketing
Discover AI agents for marketing workflows, from SEO and content production to campaign research, outreach, and analytics.
Best AI Agents for Marketing
A curated list of the best AI agents and skills for marketing teams focused on SEO, content systems, outreach, and campaign execution.
SKILL.md Source
# Components: Tab & Accordion Guides tab and accordion implementation for organizing content without excessive vertical space. Two layout patterns: **vertical accordion** (FAQ-style, stacked) and **horizontal tabs** (how-to style, side-by-side). Both improve UX by reducing scroll; SEO impact depends on implementation and content placement. **When invoking**: On **first use**, if helpful, open with 1–2 sentences on what this skill covers and why it matters, then provide the main output. On **subsequent use** or when the user asks to skip, go directly to the main output. ## Layout Patterns | Pattern | Layout | Best for | Example | |---------|--------|----------|---------| | **Vertical accordion** | Stacked; expand/collapse one at a time | FAQ, Q&A, long lists, objection handling | "How do I return?" → answer below | | **Horizontal tabs** | Side-by-side labels; one panel visible | How-to steps, product specs, pricing tiers, comparisons | "Step 1 \| Step 2 \| Step 3" | **Mobile**: Vertical accordion works well on small screens (natural scroll). Horizontal tabs can feel cramped—consider accordion, dropdown, or full-width tab bar that scrolls. ## SEO: Is It Friendly? **Google's position**: Google indexes and ranks content inside tabs and accordions fully; hidden content receives full weight (confirmed since 2016 mobile-first indexing). Gary Illyes: "we index the content, its weight is fully considered for ranking." **Practical nuance**: Some tests show always-visible content outperforms hidden content in rankings. Reserve tabs/accordions for **secondary** content; place primary, keyword-critical content in visible areas. | Content type | Placement | |--------------|-----------| | **Primary / ranking-focused** | Visible above fold; not hidden | | **Secondary / supporting** | Tabs, accordions acceptable | | **FAQ answers** | Accordion OK; first item expanded by default; see **faq-page-generator** | ### Indexing Requirements **Content must be in the DOM on page load.** Google does not simulate user clicks; it cannot "click" tabs to discover content. | Implementation | Indexed? | |----------------|----------| | All tab content in HTML at load | ✅ Yes | | Content loaded via AJAX on tab click | ❌ No | **Recommendation**: Server-render all tab content in the initial HTML; use CSS/JS only to show/hide. Prefer `<details>`/`<summary>` or equivalent server-rendered markup. See **rendering-strategies** for SSR, SSG, CSR and crawler visibility. ### Horizontal Tabs: More Tabs, More Content? **Technically**: Yes—if all content is in the DOM at load, more tabs = more indexable content. Mobile-first indexing gives full weight to tabbed content in HTML. **Strategically**: Not always. **Signal dilution** occurs when many tabs = many different topics on one page. Google may struggle to understand which query the page should rank for; topical authority and keyword focus get spread thin. | Scenario | Use tabs? | Alternative | |----------|-----------|-------------| | **Same topic** (How-to Step 1/2/3; product specs: dimensions, materials, shipping) | ✅ Yes | — | | **Different topics** (Service A, Service B, Portfolio, Blog) | ❌ No | Separate URLs per topic; see **content-strategy** for pillar/cluster | **When many horizontal tabs work**: All tabs semantically related to one query (e.g., one how-to, one product). **When to use separate pages**: Each tab is a distinct topic deserving its own URL, crawl, and ranking opportunity. ## Implementation ### Native HTML (Recommended) Use `<details>` and `<summary>`—no JavaScript required; accessible; crawlable. ```html <details open> <summary>First question (expanded by default)</summary> <p>Answer content here.</p> </details> <details> <summary>Second question</summary> <p>Answer content here.</p> </details> ``` - **First tab/accordion**: Add `open` attribute so it's expanded by default - **`<summary>`**: Must be first child of `<details>`; acts as toggle - **Progressive enhancement**: Style with CSS; add JS only if needed (e.g., close others when one opens) ### JavaScript-Dependent Tabs If using JS-only tabs: **ensure all tab content is in the DOM at page load**, not loaded via AJAX on click. Google does not simulate tab clicks. Prefer `<details>`/`<summary>` or server-rendered HTML. See **rendering-strategies**. ### Avoid - Content loaded only after user click (AJAX, lazy-loaded via fetch)—crawlers will not index it - `display: none` or `visibility: hidden` for primary content—Google may treat differently - Many tabs with unrelated topics on one page—causes signal dilution; use separate URLs instead ## Content Best Practices | Practice | Purpose | |----------|---------| | **First item expanded** | Ensures primary content visible on load; better for SEO and UX | | **Descriptive headers** | `<summary>` / tab labels should clearly describe content; include keywords naturally | | **Logical structure** | H2/H3 for sections; supports snippet extraction; see **featured-snippet** | | **Answer-first** | For FAQ: 40–60 words direct answer; then detail; see **faq-page-generator** | ## Use Cases | Use case | Format | Layout | Notes | |----------|--------|--------|-------| | **FAQ** | Accordion | Vertical | FAQPage schema; first Q expanded; see **faq-page-generator** | | **How-to steps** | Tabs | Horizontal | Step 1, Step 2, Step 3; sequential flow | | **Product specs** | Tabs | Horizontal | Dimensions, materials, shipping—secondary to hero | | **Long guides** | Accordion | Vertical | Collapsible sections; see **toc-generator** | | **Pricing tiers** | Tabs | Horizontal | Compare plans; primary CTA visible | | **Objection handling** | Accordion | Vertical | "What about X?"—supporting conversion | ## Schema & Rich Results - **FAQ (vertical accordion)**: FAQPage JSON-LD; schema must match on-page content exactly; see **schema-markup**, **faq-page-generator** - **How-to (horizontal tabs)**: HowTo schema for step-by-step content; see **howto-section-generator**, **schema-markup**, **featured-snippet** - **Other tabs**: No specific schema; ensure semantic HTML (headings, structure) ## UX & Accessibility - **Visual indicator**: Arrow, plus/minus, or chevron to show expand/collapse state - **Keyboard**: `<details>`/`<summary>` natively keyboard-accessible - **Core Web Vitals**: Avoid layout shift (CLS) when expanding; reserve space or animate smoothly - **Mobile**: Touch targets ≥44×44px; vertical accordion often better than horizontal tabs on small screens (tabs can be cramped; accordion scrolls naturally) ## Pre-Implementation Checklist - [ ] All tab/accordion content in DOM at page load (no AJAX on click) - [ ] Primary ranking content visible, not hidden - [ ] First tab/accordion expanded by default - [ ] Using `<details>`/`<summary>` or equivalent server-rendered HTML - [ ] Headers descriptive; keywords natural - [ ] Tabs share one topic (avoid signal dilution); if different topics, consider separate pages - [ ] For FAQ: FAQPage schema matches content ## Related Skills - **faq-page-generator**: FAQ structure, answer length, schema; accordion is common FAQ UI - **howto-section-generator**: HowTo section; steps in tabs vs FAQ; JSON-LD alignment - **featured-snippet**: Answer-first, H2/H3; content in accordions can be extracted - **schema-markup**: FAQPage for FAQ accordions; HowTo for step-by-step tabs - **content-strategy**: Pillar/cluster architecture; when to use separate pages vs tabs - **toc-generator**: Collapsible TOC; similar disclosure pattern - **content-optimization**: Word count, structure, multimedia in expandable sections - **rendering-strategies**: SSR, SSG, CSR; content in initial HTML for crawlers
Related Skills
website-structure
When the user wants to plan website structure, decide which pages to build, or prioritize pages for a new or existing site. Also use when the user mentions "website structure," "site structure," "which pages do I need," "page planning," "sitemap planning," "Must Have pages," "website architecture," or "site hierarchy." For a specific page template (e.g. homepage), use homepage-generator or landing-page-generator as appropriate. Not for organic SEO roadmap alone; use seo-strategy.
seo-strategy
When the user wants to plan SEO strategy, prioritize SEO work, or understand the SEO workflow. Also use when the user mentions "SEO strategy," "SEO plan," "SEO roadmap," "SEO priority," "SEO audit," "SEO workflow," "where to start SEO," "SEO approach," "organic growth strategy," "why SEO," "SEO value," or "search strategy." For technical/crawl audit execution, use seo-audit. For keyword research, use keyword-research. For AI search visibility, use generative-engine-optimization.
seo-audit
When the user wants to run an SEO audit, technical SEO audit, or site health check. Also use when the user mentions "SEO audit," "technical audit," "site audit," "crawl audit," "indexing audit," "SEO health," or "fix SEO issues." For prioritization and organic strategy, use seo-strategy. For GSC data analysis, use google-search-console.
retention-strategy
When the user wants to reduce churn, improve customer retention, or plan lifecycle marketing. Also use when the user mentions "retention," "churn," "customer lifecycle," "churn prevention," "at-risk customers," or "loyalty program." For lifecycle, use growth-funnel.
research-sources
When the user wants to find information sources for content ideation, competitor monitoring, or industry tracking. Also use when the user mentions "research sources," "information sources," "content ideation," "industry monitoring," "competitor monitoring," "market intelligence," "content research," or "topic research." For keywords, use keyword-research.
product-launch
When the user wants to plan a product launch, execute launch channels, or create a launch checklist. Also use when the user mentions "product launch," "launch strategy," "product announcement," "launch channels," or "market launch." For GTM motion and positioning, use gtm-strategy. For cold start and first users, use cold-start-strategy. For Product Hunt day-of, use product-hunt-launch.
pmf-strategy
When the user wants to validate product-market fit, measure PMF, or plan before scaling. Also use when the user mentions "PMF," "product-market fit," "product market fit," "Sean Ellis test," "very disappointed," "vitamin vs painkiller," "PMF validation," "premature scaling," or "validate before scale." For GTM after validation, use gtm-strategy.
indie-hacker-strategy
When the user wants indie hacker or bootstrapping founder strategy—growth, channels, Build in Public, or solo founder tactics. Also use when the user mentions "indie hacker," "indie developer," "bootstrapping," "bootstrapped founder," "solo founder," "Build in Public," "scratch your own itch," "Micro-SaaS," "first 100 users," or "solo company." For cold start, use cold-start-strategy.
gtm-strategy
When the user wants to plan go-to-market strategy, GTM framework, or market entry. Also use when the user mentions "GTM," "go-to-market," "market entry," "new market," "repositioning," "PLG," "sales-led," "product-led," "marketing-led," "ICP," "buyer persona," "GTM motion," or "market expansion." For launch checklist, use product-launch.
growth-funnel
When the user wants to plan growth using the AARRR framework, diagnose growth bottlenecks, or map actions across the customer lifecycle. Also use when the user mentions "growth funnel," "AARRR," "pirate metrics," "acquisition activation retention," "customer lifecycle metrics," or "growth framework." For retention tactics, use retention-strategy.
conversion-optimization
When the user wants to improve conversion rates, run A/B tests, optimize funnels, or reduce friction. Also use when the user mentions "CRO," "conversion rate optimization," "A/B test," "split test," "funnel optimization," "checkout optimization," "form optimization," or "conversion funnel." For pricing psychology, use pricing-strategy.
cold-start-strategy
When the user wants to plan cold start, get first users, or launch a new product with zero traction. Also use when the user mentions "cold start," "cold start problem," "first users," "seed users," "finding users," "finding early users," "Fiverr Upwork," "comment outreach," "Twitter search users," "product launch strategy," "0 to 1 growth," "early-stage acquisition," "launch channels," "get first customers," "Product Hunt launch," "AppSumo," "LTD," "indie hacker," "bootstrapping," or "solo founder." For directory listing copy and submissions, use directory-submission. For Product Hunt day-of execution, use product-hunt-launch. For GTM motion design, use gtm-strategy.