If you've ever tried to create HTML emails, you know the pain. What looks perfect in Gmail falls apart in Outlook 2016. Flexbox? Grid? CSS variables? Forget about it. We're still coding like it's 1999.
The Problem
Last month, I spent 2 hours debugging a simple promotional email. ChatGPT gave me clean, modern HTML. It looked great in Chrome, fine in Gmail, and completely broken in Outlook.
The issues?
- Divs don't render consistently
- Flexbox is a no-go
- CSS variables aren't supported
- Outlook has its own special "features"
I needed table-based layouts, inline CSS, and conditional comments. Writing that by hand feels like time travel to the
The Secret Sauce: Prompt Engineering
The magic isn't in the model—it's in the constraints:
You are an expert email HTML developer.
CRITICAL RULES:
1. Use <table> layout only. NO <div> for structure.
2. All CSS must be inline (style="..."). NO <style> tags.
3. NO Flexbox, Grid, or CSS variables.
4. Images must have width/height and alt attributes.
5. Buttons must be table-based for Outlook compatibility.
6. Max-width: 600px for desktop consistency.
7. Include Outlook conditional comments where needed.
OUTPUT: Complete HTML email code only. No explanations.
Real Results
Before:
- 2 hours manual coding
- 30 minutes testing in Litmus
- Still finding Outlook bugs
After:
- 30 seconds to generate
- 5 minutes to customize
- Works in all major clients
Try It Yourself
Current features:
- 5 email types (Welcome, Promotional, Newsletter, Transactional, Event)
- Natural language input
- Live preview
- One-click HTML copy
It's free — I'm validating whether this solves a real problem.
What's Next?
If people find this useful, I'm planning:
- Custom brand colors/logos
- Export to Mailchimp/HubSpot
- Litmus/Email on Acid integration
- Template library
The Bigger Picture
Email HTML is a perfect example of AI doing what humans hate. Nobody wants to write table-based layouts in 2025. But millions of emails are sent every day, and they need to work everywhere.
AI won't replace email developers. But it can handle the boilerplate, letting humans focus on strategy and design.
What do you think? Would you use something like this? What features would make it actually valuable for your workflow?
Drop a comment — I'm building this in public and need real feedback.
*P.S. If you're an email developer, I'd love your brutal honesty. Does this help, or am I solving the wrong problem?*GeoCities era.
The Solution
So I built an AI tool that generates email-client-compatible HTML from plain English descriptions.
Example input:
A welcome email with a header image, personalized greeting,
3 feature bullets, and a primary CTA button in brand blue
What it generates:
- Table-based layout (yes, really)
- Inline CSS only
- Outlook conditional comments
- Mobile-responsive structure
- Image fallbacks
The Tech Stack
AI Model: OpenAI GPT-4o-mini
- Cost: ~$0.003 per email (basically free)
- Speed: ~3 seconds generation time
- Quality: Excellent for structured HTML
Why GPT-4o-mini?
- Cost-effective for high-volume use
- Great at following strict formatting rules
- Fast enough for real-time use
Frontend: Next.js 14 + Tailwind CSS + shadcn/ui
Deployment: Vercel (free tier)
Code: GitHub Repository
Top comments (0)