vision-to-code
FreeNo executable scriptsNot checkedConvert UI screenshots and designs to working code. Use when translating visual designs, mockups, or screenshots into HTML/CSS/React components.
About this skill
👁️ Vision to Code Skill
Workflow
Step 1: Analyze Image
- Identify layout structure (grid, flex, columns)
- List all UI components
- Note colors, fonts, spacing
- Identify interactive elements
Step 2: Plan Component Structure
Page
├── Header (nav, logo, menu)
├── Hero (title, subtitle, CTA)
├── Features (grid of cards)
├── Testimonials (carousel)
└── Footer (links, social)
Step 3: Generate Code
Common Patterns
Card Component
<div className="card">
<img src={image} alt={title} className="card-image" />
<div className="card-content">
<h3 className="card-title">{title}</h3>
<p className="card-description">{description}</p>
<button className="card-button">Learn More</button>
</div>
</div>
.card {
border-radius: 12px;
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
overflow: hidden;
transition: transform 0.2s;
}
.card:hover {
transform: translateY(-4px);
}
Navigation
<nav className="navbar">
<div className="logo">Brand</div>
<ul className="nav-links">
<li><a href="#">Home</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Services</a></li>
</ul>
<button className="cta-button">Get Started</button>
</nav>
Design Token Extraction
| Visual Element | CSS Property | Example |
|---|---|---|
| Primary Color | --primary |
#6366f1 |
| Background | --bg |
#f8fafc |
| Text | --text |
#1e293b |
| Border Radius | --radius |
12px |
| Shadow | --shadow |
0 4px 6px rgba(0,0,0,0.1) |
| Font | --font |
'Inter', sans-serif |
Responsive Approach
/* Mobile First */
.container {
padding: 1rem;
}
/* Tablet */
@media (min-width: 768px) {
.container {
padding: 2rem;
}
}
/* Desktop */
@media (min-width: 1024px) {
.container {
max-width: 1200px;
margin: 0 auto;
}
}
Checklist
- วิเคราะห์ layout โครงสร้าง
- ระบุ components ทั้งหมด
- Extract design tokens (colors, fonts)
- สร้าง HTML structure
- เพิ่ม CSS styling
- ทำให้ responsive
- เพิ่ม interactivity (hover, click)
- Test บน multiple screen sizes
Install vision-to-code in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
FAQ
What does the vision-to-code skill do?
Convert UI screenshots and designs to working code. Use when translating visual designs, mockups, or screenshots into HTML/CSS/React components.
How do I install the vision-to-code skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the vision-to-code skill run scripts?
No, this skill is instructions only (SKILL.md) with no executable scripts.
Related skills
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
by Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
by Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
by Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
by Anthropic