← 返回首页
GitHub - pphatdev/github-stats: :octocat: Generate dynamic, futuristic SVG cards displaying GitHub user statistics for your README files! · GitHub
Skip to content

Navigation Menu

Toggle navigation
Sign in
Appearance settings
Search or jump to...

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Resetting focus

pphatdev/github-stats

 latest
Go to file
Code

Repository files navigation

More items

Fast GitHub Stats Graph 🚀

Create beautiful GitHub stats cards, badges, icons, and contribution graphs that are easy to customize and perfect for your profile README or project docs.

Docker build guide: docs/docker-build.md

🛜 For Load balance

Domain Owner Notes
https://stats.pphat.top @pphatdev Primary
https://stats.sophat.top @pphatdev Secondary
https://stats1.pphat.top @L-Sophat Secondary Up time only: 08:00AM -> 05:00PM Phnom Penh
https://github-stats-3hu8.onrender.com @pphatdev Secondary
https://githubstats.up.railway.app @L-Sophat Secondary

🌟 Examples Icons Usage

✨ Icon Collections

Render multiple icons into one SVG image using the name query parameter. for more detail checkout Here

Icons Sizes [small | medium | large]

![icon-collection-basic](https://stats.pphat.top/icons?name=react,typescript,github&size=small)

Preview Example

Columns [1 | 2 | 3 | 4 | 5 | 6|...] maximum 50

Customize with 3 columns

![icon-collection-basic](https://stats.pphat.top/icons?name=react,typescript,github,javascript,nextjs,nuxt&columns=3)

Preview Example

Color Mapping

Mapped colors (index by index):

![icon-collection-colors](https://stats.pphat.top/icons?name=react,typescript,github&color=%230088CC,%233178C6,white)

Example Demo

Partial colors (remaining icons use fallback colors):

![icon-collection-partial-colors](https://stats.pphat.top/icons?name=react,typescript,github,tailwindcss,postgresql&color=%2300AACC,%23EAB308)

Example Demo

Effects [glow | wave]

![icon-collection-glow](https://stats.pphat.top/icons?name=react,typescript,github,tailwindcss&effect=glow&columns=2)

Example Demo

Wave:

Glow:

Combined Example

Size + colors + wave + columns:

👍 Icon by names

Normal Icon

for more detail checkout Here

![icon-react](https://stats.pphat.top/icons/react?color=%230088CC) ![icon-python](https://stats.pphat.top/icons/python?color=%234584B6)

Example Demo

Effect icon

![icon-react](https://stats.pphat.top/icons/react?color=%230088CC&glow=true&glowColor=%230088CC) ![icon-python](https://stats.pphat.top/icons/python?color=%234584B6&glow=true&glowColor=%234584B6)

Example Demo

📊 Stats Card Examples

for more detail checkout Here

Default

![stats-default](https://stats.pphat.top/stats?username=pphatdev)

Theme + Avatar Mode

![stats-theme](https://stats.pphat.top/stats?username=pphatdev&theme=tokyonight&avatar_mode=radar)

Minimal Card

![stats-minimal](https://stats.pphat.top/stats?username=pphatdev&hide_title=true&hide_rank=true&hide_border=true)

Combined Example

![stats-combined](https://stats.pphat.top/stats?username=pphatdev&theme=dracula&custom_title=My%20GitHub%20Stats&data_border_style=frame&data_border_frame=out&show_icons=true)

💻 Languages Card Examples

for more detail checkout Here

Default

![languages-default](https://stats.pphat.top/languages?username=pphatdev)

Card and Pie

![languages-card](https://stats.pphat.top/languages?username=pphatdev&type=card) ![languages-pie](https://stats.pphat.top/languages?username=pphatdev&type=pie)

Theme + Info Style

![languages-themed](https://stats.pphat.top/languages?username=pphatdev&theme=dracula&show_info=true&info_outline=frame)

📈 Contribution Graph Examples

for more detail checkout Here

Default

![graph-default](https://stats.pphat.top/graph?username=pphatdev)

Animated Variants

![graph-wave](https://stats.pphat.top/graph?username=pphatdev&animate=wave&theme=aurora) ![graph-pulse](https://stats.pphat.top/graph?username=pphatdev&animate=pulse&theme=matrix)

🏷️ Badge Examples

Generate customizable GitHub badges for users and repositories with real-time data, caching, and visual effects.

For more details: User Badges · Badge Collections · Project Badges · Full Spec

Route

/badges?username={username}&repo={repo}&name={badge1,badge2,...}&theme={theme}&effect={wave|glow}&column={1-50}&size={small|medium|large}&p={0-100}

Parameters

Parameter Default Description
username (required) GitHub username
repo Repository name (e.g., owner/repo)
name Comma-separated badge names
theme default Comma-separated theme(s) (e.g., ocean, galaxy, aurora)
effect Animation effect: wave or glow
column 50 Number of columns (1–50)
size small Badge size: small, medium, or large
p 0 Container padding in pixels (0–100)
realtime false Bypass cache for fresh data (30s cooldown)

Supported Badge Types

User Badges: visitors · repositories · followers · organization · languages · total-stars · total-contributors · total-commits · total-code-reviews · total-issues · total-pull-requests · total-joined-years

Repository Badges (requires repo): stars · forks · contributors · issues · pull-requests · watchers · size

Single User Badge

![badge-visitors](https://stats.pphat.top/badges?username=pphatdev&name=visitors)

Multiple Badges with Theme

![badge-collection](https://stats.pphat.top/badges?username=pphatdev&name=visitors,total-stars,followers&theme=ocean&column=3&size=medium)

Multiple Themes (cycled per badge)

![badge-multi-theme](https://stats.pphat.top/badges?username=pphatdev&name=visitors,total-stars,repositories,total-issues,followers&theme=galaxy,aurora,ocean)

Repository Badges

![repo-badges](https://stats.pphat.top/badges?username=pphatdev&repo=github-stats&name=stars,forks,contributors&theme=galaxy&effect=wave)

Effects (glow | wave)

![badge-glow](https://stats.pphat.top/badges?username=pphatdev&name=visitors,total-stars,repositories,total-issues&effect=glow) ![badge-wave](https://stats.pphat.top/badges?username=pphatdev&name=visitors,total-stars,repositories,total-issues&effect=wave)

Combined Example (layout + themes + effect + padding)

![badge-combined](https://stats.pphat.top/badges?username=pphatdev&name=visitors,total-stars,repositories,total-issues,followers,total-pull-requests&column=3&theme=galaxy,aurora,ocean&effect=wave&size=large&p=15)

Fresh Data with Realtime

![badge-realtime](https://stats.pphat.top/badges?username=pphatdev&name=total-stars&realtime=true)

Development

Documentation:

Architecture

  • API: GitHub REST + GraphQL APIs with intelligent batching
  • Caching: Multi-tier (Memory → Redis → Source) with 2-hour default TTL
  • Database: SQLite with Drizzle ORM for badge counters and visitor logs
  • Server: Express.js with round-robin cluster load balancing in production
  • Rendering: Server-side SVG generation with optional WebP/PNG/GIF export

Notes

  • Responses are cached for 2 hours (configurable via CACHE_DURATION)
  • Without a GitHub token, API rate limits are very low (~60 requests/hour)
  • Set GITHUB_TOKEN to get 5,000 requests/hour
  • Redis is optional but recommended for production (enables distributed caching)
  • Docker and npm start now boot the clustered entrypoint; set WORKERS to cap worker count, or leave it at 0 to use all available CPU cores
  • User visitor badges (/badges?username=...&name=visitors) use IP hashing for privacy-preserving unique visitor counting
  • Project visitor badges (/project/visitors) increment once per same IP every 5 minutes

License

MIT. See LICENSE.

About

Generate dynamic, futuristic SVG cards displaying GitHub user statistics for your README files!

Topics

Resources

License

Code of conduct

Contributing

Stars

24 stars

Watchers

0 watching

Forks

Packages

 
 
 

Contributors

Footer

© 2026 GitHub, Inc.