A comprehensive Next.js dashboard for monitoring Claude usage analytics, cost insights, and code statistics with real-time data visualization.
- Real-time Usage Analytics: Monitor Claude usage patterns with live data updates
- Cost Insights: Track spending across different time periods (daily, weekly, monthly)
- Multi-Currency Support: View costs in USD and INR with real-time exchange rates
- Interactive Charts: Beautiful data visualizations using Recharts
- Dark/Light Theme: Toggle between dark and light modes
- Internationalization: Support for English and Hindi languages
- Responsive Design: Mobile-friendly interface built with Tailwind CSS
- Docker Support: Easy deployment with Docker and Docker Compose
- Total usage statistics
- Cost breakdown by time period
- Usage trends and patterns
- Real-time data refresh
- Interactive bar charts
- Area charts for trend analysis
- Progress indicators
- Tabbed interface for different views
- Currency conversion (USD/INR)
- Multi-language support (EN/HI)
- Theme switching
- Responsive design for all devices
- Framework: Next.js 15.3.3
- Language: TypeScript 5.8.3
- UI Library: React 19.1.0
- Styling: Tailwind CSS 3.4.17
- Charts: Recharts 2.15.3
- Icons: Lucide React 0.512.0
- UI Components: Radix UI
- Deployment: Docker & Docker Compose
- Node.js 18+ (recommended)
- npm or yarn
- Claude CLI (
ccusagepackage) - Docker (optional, for containerized deployment)
-
Clone the repository
git clone https://github.com/tanu360/claude-code-dashboard.git cd claude-code-dashboard -
Install dependencies
npm install
-
Run the development server
npm run dev
-
Open your browser Navigate to http://localhost:3000
-
Using Docker Compose (Recommended)
docker-compose up -d
The dashboard will be available at http://localhost:3300
-
Using Docker directly
docker build -t claude-dashboard . docker run -p 3000:3000 \ -v ~/.claude/db:/home/nextjs/.claude/db:ro \ claude-dashboard
npm run build
npm startclaude-code-dashboard/
βββ src/
β βββ app/
β β βββ api/
β β β βββ usage/ # Usage data API endpoint
β β β βββ exchange-rate/ # Currency exchange API
β β βββ globals.css # Global styles
β β βββ layout.tsx # Root layout
β β βββ page.tsx # Main dashboard page
β βββ components/
β β βββ ui/ # Reusable UI components
β β βββ theme-provider.tsx # Theme context
β βββ lib/
β β βββ utils.ts # Utility functions
β βββ locales/ # Internationalization
β β βββ en.ts # English translations
β β βββ hi.ts # Hindi translations
β β βββ index.ts # Locale exports
β βββ types/
β βββ usage.ts # TypeScript type definitions
βββ public/ # Static assets
βββ docker-compose.yml # Docker Compose configuration
βββ Dockerfile # Docker build configuration
βββ package.json # Dependencies and scripts
The application uses the following environment variables:
NODE_ENV: Set toproductionfor production buildsHOME: Home directory path (used in Docker)
Make sure you have the Claude CLI installed and configured:
npm install -g ccusage@latestThe dashboard uses the ccusage command to fetch usage statistics.
- GET
/api/usage- Fetch Claude usage statistics
- GET
/api/exchange-rate?date=YYYY-MM-DD- Get USD to INR exchange rate
The dashboard supports both light and dark themes. Theme switching is handled by the ThemeProvider component.
Add new languages by creating translation files in the src/locales/ directory and updating the locale index.
Customize the appearance by modifying the Tailwind CSS configuration in tailwind.config.js.
- Fork this repository
- Connect your GitHub account to Vercel
- Import the project
- Deploy automatically
The application can be deployed on any platform that supports Next.js:
- Netlify
- Railway
- Heroku
- DigitalOcean App Platform
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
npm run dev- Start development servernpm run build- Build for productionnpm run start- Start production servernpm run lint- Run ESLint
If you encounter any issues, please check the following:
- Ensure Claude CLI (
ccusage) is properly installed - Check that your Claude database is accessible
- Verify Docker permissions (for Docker deployment)
For bug reports and feature requests, please open an issue.
This project is licensed under the MIT License - see the LICENSE file for details.
- Next.js for the amazing React framework
- Tailwind CSS for the utility-first CSS framework
- Recharts for beautiful data visualizations
- Radix UI for accessible UI components
- Lucide for the beautiful icons
For support, please reach out through:
- GitHub Issues: Issues Page
- Repository: Claude Code Dashboard
Made with β€οΈ using Next.js and TypeScript



