UI/UX Design Guide for Developers
Create beautiful, user-friendly interfaces
Good design isn't just about making things pretty—it's about making things work. Here's everything developers need to know about UI/UX design.
UI vs UX: What's the Difference?
UI (User Interface)
The visual elements users interact with
- Colors, typography, spacing
- Buttons, icons, images
- Layout and composition
- Animations and transitions
- Visual hierarchy
UX (User Experience)
How users feel using your product
- User research
- Information architecture
- User flows and journeys
- Wireframes and prototypes
- Usability testing
Analogy: UI is the steering wheel, pedals, and dashboard. UX is how it feels to drive the car.
Core Design Principles
1. Visual Hierarchy
Guide users' attention to the most important elements.
- Size: Bigger = more important
- Color: Bright colors attract attention
- Contrast: Stand out from surroundings
- Proximity: Related items grouped together
- White space: Give elements room to breathe
2. Consistency
Keep patterns predictable throughout your app.
Be consistent with:
- Button styles and positions
- Color meanings (green = success, red = error)
- Typography scale
- Icon styles
- Spacing system
3. Feedback
Let users know what's happening.
- Button hover states
- Loading indicators
- Success/error messages
- Form validation (real-time)
- Disabled state (when button isn't clickable)
4. Accessibility
15% of the world has a disability. Design for everyone.
- Color contrast: 4.5:1 ratio minimum (use contrast checker)
- Font size: 16px minimum for body text
- Keyboard navigation: Tab through all interactive elements
- Alt text: Describe all images
- Focus indicators: Show which element is focused
- ARIA labels: For screen readers
5. Simplicity
Less is more. Remove anything that doesn't serve a purpose.
"Perfection is achieved not when there is nothing more to add, but when there is nothing left to take away." — Antoine de Saint-Exupéry
Color Theory for Developers
60-30-10 Rule
- 60%: Primary color (background, main UI)
- 30%: Secondary color (cards, sections)
- 10%: Accent color (buttons, links, highlights)
Color Palette Creation
- Choose brand color: Your main color (e.g., blue)
- Create shades: 9 shades from light to dark
- 50: lightest (backgrounds)
- 100-400: light shades
- 500: main color
- 600-900: dark shades
- Add neutrals: Gray scale (white to black)
- Semantic colors:
- Success: Green
- Warning: Yellow/Orange
- Error: Red
- Info: Blue
Tools: Coolors.co, Adobe Color, Tailwind CSS colors
Typography Guidelines
Font Selection
- Maximum 2 fonts: One for headings, one for body
- Sans-serif for web: Easier to read on screens
- Good pairings:
- Roboto + Open Sans
- Montserrat + Lato
- Playfair Display + Source Sans Pro
Type Scale
Recommended sizes:
- H1: 48-60px (mobile: 32-40px)
- H2: 36-48px (mobile: 28-32px)
- H3: 28-36px (mobile: 24-28px)
- H4: 24-28px (mobile: 20-24px)
- Body: 16-18px
- Small: 14px
Readability Rules
- Line height: 1.5-1.8 for body text
- Line length: 50-75 characters per line
- Letter spacing: Slightly increased for ALL CAPS
- Paragraph spacing: 1.5x line height
Spacing & Layout
8-Point Grid System
Use multiples of 8 for all spacing and sizing.
Spacing scale:
- 4px: Tiny (icon padding)
- 8px: Small (button padding)
- 16px: Medium (card padding)
- 24px: Large (section spacing)
- 32px: XL (between sections)
- 48px: 2XL (page margins)
- 64px: 3XL (hero sections)
White Space
Empty space is not wasted space—it's essential for clarity.
- Improves readability
- Creates visual hierarchy
- Makes designs feel premium
- Reduces cognitive load
Component Design
Buttons
Best Practices:
- Size: Minimum 44x44px (Apple) or 48x48px (Google)
- Padding: 12px vertical, 24px horizontal
- Border radius: 4-8px (modern), 24px+ (pill)
- States: Default, hover, active, disabled, loading
- Text: Action-oriented ("Save Changes" not "Submit")
Forms
- Labels: Above input, not placeholder
- Input height: 40-48px minimum
- Focus state: Clear border/shadow
- Validation: Real-time, helpful error messages
- Auto-complete: Enable for common fields
- Password: Show/hide toggle
Cards
- Border radius: 8-16px
- Shadow: Subtle (2-4px blur)
- Padding: 16-24px
- Hover state: Slight lift/shadow increase
UX Process
1. Research
- User interviews: Talk to 5-10 potential users
- Competitor analysis: What works? What doesn't?
- User personas: Who are you designing for?
- Pain points: What problems are users facing?
2. Wireframes
Low-fidelity sketches of layout (no colors/images).
- Focus on structure, not visuals
- Quick to create and iterate
- Tools: Figma, Sketch, Balsamiq, pen & paper
3. Prototypes
Interactive mockups that simulate the real product.
- Click-through flows
- Test before coding
- Tools: Figma, Adobe XD, InVision
4. User Testing
Watch real users interact with your design.
Questions to ask:
- "What do you think this button does?"
- "How would you complete [task]?"
- "What's confusing about this page?"
- "What would you change?"
5. Iterate
Based on feedback, make improvements and test again.
Design Psychology
Hick's Law
More choices = longer decision time. Limit options to 5-7.
Miller's Law
People can hold 7±2 items in working memory. Chunk information.
Fitts's Law
Larger targets are easier to click. Make important buttons bigger.
Jakob's Law
Users prefer familiar patterns. Don't reinvent the wheel.
Common UX Mistakes
❌ Avoid:
- Too many font styles
- Low contrast text
- Unclear CTAs
- Slow loading times
- No mobile optimization
- Hidden navigation
- Auto-playing videos/music
- Unclear error messages
- Forcing registration too early
- Disabled copy/paste in forms
Design Tools for Developers
Design Software
- Figma: Best for collaboration (free)
- Adobe XD: Good for prototyping
- Sketch: Mac-only, popular with designers
Useful Resources
- Colors: Coolors.co, Adobe Color
- Fonts: Google Fonts, Font Pair
- Icons: Heroicons, Feather Icons, Font Awesome
- Images: Unsplash, Pexels
- Inspiration: Dribbble, Behance, Awwwards
- Components: UI Kit, Material Design
Handoff to Development
Include:
- Design specs (spacing, sizes)
- Color codes (hex, RGB)
- Font details (family, size, weight)
- Component states
- Responsive breakpoints
- Animations & transitions
- Assets (icons, images)
Quick Design Checklist
- ✅ Clear visual hierarchy
- ✅ Consistent design system
- ✅ Accessible (color contrast, font size)
- ✅ Mobile responsive
- ✅ Fast loading
- ✅ Clear CTAs
- ✅ Intuitive navigation
- ✅ Helpful feedback (hover, loading, errors)
- ✅ White space
- ✅ Consistent spacing (8px grid)
- ✅ User-tested
- ✅ Follows familiar patterns
Need Professional UI/UX Design?
We create beautiful, user-friendly interfaces that your customers will love. Research-backed designs optimized for conversions.
Start Your Design Project