
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
Hacker News (YC) MCP server for Claude & AI assistants. Browse HN stories, search posts, read comments, analyze users.
A Model Context Protocol (MCP) server that enables Claude Desktop and other AI assistants to browse Hacker News, search discussions, and analyze tech trends. Clean, fast, and actually works - no API keys required.
Add this to your claude_desktop_config.json:
{
"mcpServers": {
"hn": {
"command": "npx",
"args": ["hn-mcp"]
}
}
}
That's it! HN-MCP is now available in Claude.
Ask your AI assistant to:
browse_storiesBrowse posts from Hacker News by category.
- Types: top, new, best, ask (Ask HN), show (Show HN), job
- Limit: 1-100 stories (default: 30)
- Returns: Title, score, author, comments, URL
search_hnSearch across all Hacker News content.
- Query: Your search terms
- Filter by: Type, date range, author
- Sort by: relevance or date
- Uses: Algolia's HN Search API
get_story_detailsGet a story with all its comments.
- Input: Story ID
- Returns: Full story + nested comment threads
- Options: Max comments, thread depth
user_analysisAnalyze a Hacker News user's profile.
- Username: Any HN user
- Returns: Karma, account age, recent submissions
- Insights: Activity patterns, top posts
hn_explainGet explanations of HN terms.
- Terms: karma, flagged, dupe, Show HN, Ask HN, etc.
- Returns: Definition + context
Easiest method - One-click install for Claude Desktop:
hn-mcp.mcpb from latest releaseThat's it! HN-MCP will be available immediately.
# Claude Desktop - add to config (see Quick Start above)
npx hn-mcp
# HTTP mode for testing
HN_MCP_HTTP=true npx hn-mcp
npm install -g hn-mcp
hn-mcp # Run in stdio mode
HN_MCP_HTTP=true hn-mcp # Run in HTTP mode
# Quick start - HTTP mode for API access
docker run -e HN_MCP_HTTP=true -p 3000:3000 karanb192/hn-mcp:latest
# stdio mode for development
docker run -it karanb192/hn-mcp:latest
# With docker-compose
docker-compose up
git clone https://github.com/karanb192/hn-mcp.git
cd hn-mcp
npm install
npm run build
npm link
| API | Official Limit | Our Limit | Notes |
|---|---|---|---|
| HN Firebase | None ✅ | 300/min | Self-imposed for courtesy |
| Algolia Search | None ✅ | 300/min | Max 1000 results per query |
@someone/hn-something is hard to rememberhn-mcp"What are the top posts about GPT-4 today?"
→ search_hn with query="GPT-4", dateRange="last24h", sortBy="relevance"
"Show me what's trending on Hacker News"
→ browse_stories with type="top", limit=10
"What are people saying about this article?"
→ search_hn with the article URL to find discussions
"Analyze the user dang"
→ user_analysis with username="dang"
"Get the comments from HN story 12345678"
→ get_story_details with id="12345678"
"Command not found" error
# Ensure npm is installed
node --version
npm --version
# Try with full npx path
$(npm bin -g)/hn-mcp
Connection issues
Search returns max 1000 results
Configure HN-MCP using environment variables. See .env.example for detailed documentation.
| Variable | Description | Default |
|---|---|---|
HN_MCP_HTTP | Run as HTTP server instead of stdio | false |
HN_MCP_PORT | HTTP server port | 3000 |
HN_MCP_NO_CACHE | Disable caching for real-time data | false |
HN_MCP_RATE_LIMIT | Override rate limit (requests/minute) | 300 |
Quick setup:
# Copy example file
cp .env.example .env
# Edit with your preferences
nano .env
# Install dependencies
npm install
# Run in development
npm run dev
# Build
npm run build
# Run tests
npm run typecheck
# Deploy locally
./deploy-server.sh # Port 3000
./deploy-server.sh -p 8080 # Custom port
# Docker build
docker build -t karanb192/hn-mcp .
docker run -e HN_MCP_HTTP=true -p 3000:3000 karanb192/hn-mcp
# Docker development with hot reload
docker-compose --profile dev up
PRs welcome! See CONTRIBUTING.md for guidelines.
We keep things simple:
MIT - Use it however you want!
Made with ❤️ for the MCP community by the creator of reddit-mcp-buddy. No venture capital, no tracking, just a good MCP server.
FAQs
Hacker News (YC) MCP server for Claude & AI assistants. Browse HN stories, search posts, read comments, analyze users.
The npm package hn-mcp receives a total of 20 weekly downloads. As such, hn-mcp popularity was classified as not popular.
We found that hn-mcp demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.