https://github.com/nitinsemwal2605/fontpilot.io
FontPilot.io is an AI-powered tool that helps designers and developers instantly find perfect font combinations based on mood, brand style, or font name. It generates beautiful pairings using Google Fonts, shows live previews on real UI layouts, and offers exportable CSS/font links โ making typography effortless, aesthetic, and shareable.
https://github.com/nitinsemwal2605/fontpilot.io
fonts frontend google-fonts saas ui-design vercel
Last synced: about 2 months ago
JSON representation
FontPilot.io is an AI-powered tool that helps designers and developers instantly find perfect font combinations based on mood, brand style, or font name. It generates beautiful pairings using Google Fonts, shows live previews on real UI layouts, and offers exportable CSS/font links โ making typography effortless, aesthetic, and shareable.
- Host: GitHub
- URL: https://github.com/nitinsemwal2605/fontpilot.io
- Owner: NitinSemwal2605
- Created: 2025-08-04T05:01:09.000Z (2 months ago)
- Default Branch: main
- Last Pushed: 2025-08-04T10:17:12.000Z (2 months ago)
- Last Synced: 2025-08-30T18:04:06.272Z (about 2 months ago)
- Topics: fonts, frontend, google-fonts, saas, ui-design, vercel
- Language: TypeScript
- Homepage: https://fontpilotio.vercel.app
- Size: 1.15 MB
- Stars: 6
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# FontPilot.io ๐จ
Navigate typography with precision. An intelligent, AI-powered font pairing assistant designed for modern designers, developers, and creators who want to elevate their typography game without spending hours on experimentation.
## โจ Features
- **AI-Powered Navigation**: Navigate typography with precision using intelligent algorithms that understand your design needs
- **Live Previews**: Experience your font choices in real-time with live previews of headers, blog titles, and landing pages
- **Export CSS**: Get production-ready CSS code with Google Fonts links and optimized font-family declarations
- **Share & Save**: Build your typography library by saving favorite combinations and sharing them with your team
- **Instant Results**: Navigate to perfect typography in seconds, not hours. Get beautiful font pairings instantly
- **Google Fonts Integration**: Access the complete Google Fonts library with expertly curated pairings that harmonize perfectly## ๐ Getting Started
### Prerequisites
- **Node.js 18+** (for Next.js 14 features)
- **npm or yarn** (package manager)
- **Git** (for version control)### Quick Start
1. **Clone the repository:**
```bash
git clone https://github.com/NitinSemwal2605/fontpilot-io.git
cd fontpilot-io
```2. **Install dependencies:**
```bash
npm install
# or
yarn install
```3. **Set up environment variables:**
```bash
# Create .env.local file
cp .env.example .env.local# Edit .env.local with your API keys
NEXT_PUBLIC_GOOGLE_FONTS_API_KEY=your_google_fonts_api_key
NEXT_PUBLIC_GOOGLE_GEMINI_API_KEY=your_google_gemini_api_key
```4. **Run the development server:**
```bash
npm run dev
# or
yarn dev
```5. **Open your browser:**
Navigate to [http://localhost:3000](http://localhost:3000)## ๐ง Environment Variables
Create a `.env.local` file in the root directory with the following variables:
```bash
# Google Fonts API Key
NEXT_PUBLIC_GOOGLE_FONTS_API_KEY=your_google_fonts_api_key_here# Google Gemini AI API Key
NEXT_PUBLIC_GOOGLE_GEMINI_API_KEY=your_google_gemini_api_key_here
```### Getting API Keys
1. **Google Fonts API**:
- Go to [Google Cloud Console](https://console.cloud.google.com/)
- Enable the Google Fonts API
- Create credentials and get your API key2. **Google Gemini AI API**:
- Go to [Google AI Studio](https://makersuite.google.com/app/apikey)
- Create a new API key for Gemini Pro## ๐ ๏ธ Tech Stack
- **Framework**: Next.js 14 with App Router
- **Styling**: Tailwind CSS with custom animations
- **UI Components**: shadcn/ui with Radix UI primitives
- **Animations**: Framer Motion
- **Icons**: Lucide React
- **TypeScript**: Full type safety
- **Toast Notifications**: react-hot-toast
- **SEO**: Structured data, sitemap, robots.txt
- **PWA**: Web app manifest for mobile experience
- **AI Integration**: Google Gemini Pro for intelligent recommendations
- **Font Management**: Google Fonts API integration## ๐ฏ Usage
1. **AI-Powered Search**: Describe your project like "Building a SaaS landing page" or "Creating a wedding website"
2. **Browse Categories**: Explore curated collections by style (Professional, Creative, Modern, etc.)
3. **Live Previews**: See font combinations in real UI components
4. **Export CSS**: Copy production-ready CSS with Google Fonts links
5. **Save Favorites**: Build your typography library with saved combinations## ๐จ Design System
The application uses a modern design system with:
- Gradient text effects
- Smooth animations and transitions
- Glass morphism effects
- Responsive design
- Dark mode support (coming soon)## ๐ฑ Responsive Design
FontPair.ai is fully responsive and works beautifully on:
- Desktop (1200px+)
- Tablet (768px - 1199px)
- Mobile (320px - 767px)## ๐ง Environment Variables
Create a `.env.local` file in the root directory with the following variables:
```bash
# Google Fonts API Key
NEXT_PUBLIC_GOOGLE_FONTS_API_KEY=your_google_fonts_api_key_here# Google Gemini AI API Key
NEXT_PUBLIC_GOOGLE_GEMINI_API_KEY=your_google_gemini_api_key_here
```### Getting API Keys
1. **Google Fonts API**:
- Go to [Google Cloud Console](https://console.cloud.google.com/)
- Enable the Google Fonts API
- Create credentials and get your API key2. **Google Gemini AI API**:
- Go to [Google AI Studio](https://makersuite.google.com/app/apikey)
- Create a new API key for Gemini Pro## ๐ Project Structure
```
fontpilot-io/
โโโ app/ # Next.js 14 App Router
โ โโโ components/ # Shared components
โ โ โโโ structured-data.tsx # SEO structured data
โ โโโ favorites/ # Favorites page
โ โ โโโ page.tsx
โ โโโ globals.css # Global styles
โ โโโ layout.tsx # Root layout with metadata
โ โโโ manifest.ts # PWA manifest
โ โโโ page.tsx # Home page
โ โโโ robots.ts # SEO robots.txt
โ โโโ sitemap.ts # SEO sitemap
โโโ components/ # Reusable components
โ โโโ ui/ # shadcn/ui components
โ โ โโโ button.tsx
โ โ โโโ card.tsx
โ โ โโโ input.tsx
โ โโโ features.tsx # Features section
โ โโโ footer.tsx # Footer component
โ โโโ font-card.tsx # Font pair card
โ โโโ font-preview.tsx # Font loading component
โ โโโ navigation.tsx # Navigation bar
โ โโโ ai-reasoning.tsx # AI reasoning display
โโโ lib/ # Utility libraries
โ โโโ ai-recommendations.ts # AI integration
โ โโโ favorites.ts # Local storage management
โ โโโ fonts.ts # Google Fonts integration
โ โโโ font-styles.ts # Font categorization
โ โโโ utils.ts # Utility functions
โโโ public/ # Static assets
โโโ package.json # Dependencies
```## ๐๏ธ Architecture Overview
### Core Components
1. **AI Integration** (`lib/ai-recommendations.ts`)
- Google Gemini Pro integration
- Context-aware font recommendations
- Fallback recommendations for different use cases2. **Font Management** (`lib/fonts.ts`)
- Google Fonts API integration
- Dynamic font loading
- Font categorization and filtering3. **State Management**
- React hooks for local state
- Local storage for favorites
- Session storage for font previews4. **UI Components**
- Modular component architecture
- Reusable shadcn/ui components
- Responsive design with Tailwind CSS### Key Features Implementation
#### AI-Powered Recommendations
```typescript
// lib/ai-recommendations.ts
export async function getAIRecommendations(userNeed: string): Promise
```
- Analyzes user input for context
- Generates 10 tailored font combinations
- Provides reasoning and use cases#### Font Loading System
```typescript
// lib/fonts.ts
export function loadFontsForPair(headingFont: string, bodyFont: string): Promise
```
- Dynamic Google Fonts loading
- Prevents duplicate font requests
- Handles loading states#### Favorites System
```typescript
// lib/favorites.ts
export function addToFavorites(fontPair: FontPair): boolean
```
- Local storage persistence
- Add/remove functionality
- Dedicated favorites page## ๐ง Development Guidelines
### Code Style
- **TypeScript**: Strict type checking enabled
- **ESLint**: Code quality and consistency
- **Prettier**: Automatic code formatting
- **Component Structure**: Functional components with hooks### Adding New Features
1. **New Font Categories**
```typescript
// Add to lib/font-styles.ts
export const fontStyles = {
'New Category': {
icon: '๐จ',
color: 'text-blue-500',
description: 'Description here'
}
}
```2. **New AI Recommendations**
```typescript
// Add to lib/ai-recommendations.ts
const newRecommendations = [
{
heading: 'Font Name',
body: 'Font Name',
category: 'Category',
description: 'Description',
reasoning: 'Why this works',
useCase: 'Specific use case'
}
]
```3. **New UI Components**
```typescript
// Create in components/
export default function NewComponent() {
return (
{/* Component content */}
)
}
```### Environment Setup
1. **Development**
```bash
npm run dev
```2. **Build for Production**
```bash
npm run build
npm start
```3. **Type Checking**
```bash
npm run type-check
```4. **Linting**
```bash
npm run lint
```## ๐งช Testing
### Manual Testing Checklist
- [ ] AI recommendations work for different inputs
- [ ] Font loading and preview functionality
- [ ] Favorites system (add/remove/save)
- [ ] CSS export functionality
- [ ] Responsive design on different screen sizes
- [ ] SEO metadata and structured data
- [ ] PWA functionality### Performance Testing
- [ ] Font loading performance
- [ ] AI response times
- [ ] Bundle size optimization
- [ ] Lighthouse scores## ๐ Deployment
### Vercel (Recommended)
1. Connect your GitHub repository
2. Set environment variables in Vercel dashboard
3. Deploy automatically on push to main branch### Other Platforms
- **Netlify**: Similar to Vercel setup
- **Railway**: Container-based deployment
- **AWS/GCP**: Custom server setup## ๐ค Contributing
1. **Fork the repository**
2. **Create a feature branch**: `git checkout -b feature/amazing-feature`
3. **Commit your changes**: `git commit -m 'Add amazing feature'`
4. **Push to the branch**: `git push origin feature/amazing-feature`
5. **Open a Pull Request**### Contribution Guidelines
- Follow TypeScript best practices
- Add proper error handling
- Include loading states for async operations
- Test on multiple browsers
- Update documentation for new features## ๐ License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
## ๐ Acknowledgments
- **Google Fonts API** for font data
- **Google Gemini Pro** for AI recommendations
- **shadcn/ui** for beautiful components
- **Framer Motion** for smooth animations
- **Tailwind CSS** for utility-first styling## ๐ Support
- **GitHub Issues**: [Report bugs or request features](https://github.com/NitinSemwal2605/fontpilot-io/issues)
- **Email**: 55semwalnitin@gmail.com
- **Twitter**: [@nitintweetz](https://x.com/nitintweetz)---
**Made with โค๏ธ by [Nitin Semwal](https://github.com/NitinSemwal2605)**
- `.animate-gradient-shift`: Animated gradient background## ๐ค Contributing
1. Fork the repository
2. Create a feature branch: `git checkout -b feature/amazing-feature`
3. Commit your changes: `git commit -m 'Add amazing feature'`
4. Push to the branch: `git push origin feature/amazing-feature`
5. Open a Pull Request## ๐ License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
## ๐ Acknowledgments
- [Google Fonts](https://fonts.google.com/) for the font library
- [shadcn/ui](https://ui.shadcn.com/) for the component library
- [Framer Motion](https://www.framer.com/motion/) for animations
- [Tailwind CSS](https://tailwindcss.com/) for styling## ๐ Support
- ๐ Report bugs: [GitHub Issues](https://github.com/yourusername/fontpair-ai/issues)
- ๐ก Feature requests: [GitHub Discussions](https://github.com/yourusername/fontpair-ai/discussions)
- ๐ง Email: hello@fontpair.ai---
Made with โค๏ธ for designers and developers