Interact with Hacker News through the Model Context Protocol (MCP), designed for Claude Desktop.
git clone https://github.com/imprvhub/mcp-claude-hackernews
cd mcp-claude-hackernews
npm install
npm run build
There are two ways to run the MCP server:
node build/index.js
Keep this terminal window open while using Claude Desktop. The server will run until you close the terminal.
The Claude Desktop can automatically start the MCP server when needed. To set this up:
The Claude Desktop configuration file is located at:
~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%\Claude\claude_desktop_config.json
~/.config/Claude/claude_desktop_config.json
Edit this file to add the Hacker News MCP configuration. If the file doesn't exist, create it:
{
"mcpServers": {
"hackerNews": {
"command": "node",
"args": ["ABSOLUTE_PATH_TO_DIRECTORY/mcp-claude-hackernews/build/index.js"]
}
}
}
Important: Replace ABSOLUTE_PATH_TO_DIRECTORY
with the complete absolute path where you installed the MCP
/Users/username/mcp-claude-hackernews
C:\\Users\\username\\mcp-claude-hackernews
If you already have other MCPs configured, simply add the "hackerNews" section inside the "mcpServers" object. Here's an example of a configuration with multiple MCPs:
{
"mcpServers": {
"otherMcp1": {
"command": "...",
"args": ["..."]
},
"otherMcp2": {
"command": "...",
"args": ["..."]
},
"hackerNews": {
"command": "node",
"args": [
"ABSOLUTE_PATH_TO_DIRECTORY/mcp-claude-hackernews/build/index.js"
]
}
}
}
The MCP server will automatically start when Claude Desktop needs it, based on the configuration in your claude_desktop_config.json
file.
The Hacker News MCP provides 5 specialized tools for different functions:
Tool | Description | Parameters | Example Usage |
---|---|---|---|
hn_latest | Get the most recent stories from Hacker News | limit : Optional number of stories (1-50, default: 10) | Get 20 latest stories |
hn_top | Get the top-ranked stories from Hacker News | limit : Optional number of stories (1-50, default: 10) | Get 15 top stories |
hn_best | Get the best stories from Hacker News | limit : Optional number of stories (1-50, default: 10) | Get 25 best stories |
hn_story | Get detailed information about a specific story | story_id : Required story ID (number) | Get story details by ID |
hn_comments | Get comments for a story | story_id : Story ID (number) OR story_index : Index from last list (1-based) | Get comments by story ID or index |
hn_latest
, hn_top
, hn_best
limit
(optional): Number of stories to fetch
hn_story
story_id
(required): The ID of the story to fetch
hn_comments
story_id
(optional): The ID of the story to get comments for
story_index
(optional): The index of the story from the last fetched list
Note: For hn_comments
, you must provide either story_id
OR story_index
Here are various examples of how to use the Hacker News MCP with Claude:
"Use hn_latest to get 20 recent stories"
"Use hn_top with limit 15 to get top stories"
"Use hn_best to get 25 best stories"
"Use hn_story with story_id 29384756 to get story details"
"Use hn_comments with story_index 3 to get comments for the 3rd story"
"Use hn_comments with story_id 12345678 to get comments for that story"
You can also interact with the MCP using natural language. Claude will interpret these requests and use the appropriate tools:
You can request Hacker News content to be translated into different languages:
If you see the error "MCP Hacker News: Server disconnected" in Claude Desktop:
Verify the server is running:
node build/index.js
from the project directoryCheck your configuration:
claude_desktop_config.json
is correct for your system\\
) for Windows pathsTry the auto-start option:
If the Hacker News tools don't appear in Claude:
To check if the server is running:
ps aux | grep node
If you don't see the server running, start it manually or use the auto-start method.
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the Mozilla Public License 2.0 - see the LICENSE file for details.
MCP server acting as an interface to the Facebook Ads, enabling programmatic access to Facebook Ads data and management features.
TikTok integration for getting post details and video subtitles
Connect AI assistants like Cursor to Google Chat and beyond — enabling smart, extensible collaboration across chat platforms.
Integrates with the LinkedIn API, allowing interaction with your professional network and content.
Enables room-based messaging between multiple agents.
An MCP service for device communication and PWM control via the MQTT protocol.
Provides access to Intercom conversations and chats. Requires an Intercom API key.
Enables interactive LLM workflows by adding local user prompts and chat capabilities directly into the MCP loop.
Send push notifications via the Pushinator service. Requires an API token from your Pushinator account.
Simple MCP Server to enable a human-in-the-loop workflow in tools like Cline and Cursor.