Fire in da houseTop Tip:Paying $100+ per month for Perplexity, MidJourney, Runway, ChatGPT and other tools is crazy - get all your AI tools in one site starting at $15 per month with Galaxy AI Fire in da houseCheck it out free

hn-mcp

MCP.Pizza Chef: devabdultech

The hn-mcp server provides real-time integration with Hacker News through the Model Context Protocol. It enables LLM clients like Cursor and Claude to access Hacker News stories, comments, user profiles, and search functionality seamlessly. Features include searching stories and comments via Algolia's HN Search API, retrieving story types (top, new, best, ask, show, job), fetching comment trees, and user discussions, making it a powerful tool for embedding Hacker News data into AI workflows.

Use This MCP server To

Search Hacker News stories and comments via Algolia API Retrieve top, new, best, ask, show, and job stories Fetch detailed story data with nested comments Access user profiles and their submissions Integrate real-time Hacker News data into LLM workflows Enable LLMs to generate insights from Hacker News discussions Support research by extracting Hacker News trends and topics

README

Hacker News MCP Server

smithery badge Official Hacker News MCP Server - Adds powerful Hacker News integration to Cursor, Claude, and any other LLM clients. Access stories, comments, user profiles, and search functionality through the Model Context Protocol.

Hacker News Server MCP server

Features

  • Search stories and comments using Algolia's HN Search API
  • Get stories by type (top, new, best, ask, show, job)
  • Get individual stories with comments
  • Get comment trees and user discussions
  • Get user profiles and submissions
  • Real-time access to Hacker News data

Set Up

Running on Claude Desktop

Add this to your claude_desktop_config.json:

{
  "mcpServers": {
    "hackernews": {
      "command": "npx",
      "args": ["-y", "@devabdultech/hn-mcp-server"]
    }
  }
}

Installing via Smithery

To install Hacker News MCP Server for Claude Desktop automatically via Smithery:

npx -y @smithery/cli install @devabdultech/hn-mcp --client claude

Tools

  1. search

    • Search for stories and comments on Hacker News using Algolia's search API
    • Inputs: * query (string): Search query * type (optional string): Filter by type ('story' or 'comment') * page (optional number): Page number for pagination * hitsPerPage (optional number): Results per page (max 100)
    • Returns: Search results with stories and comments
  2. getStories

    • Get multiple stories by type (top, new, best, ask, show, job)
    • Inputs: * type (string): Type of stories to fetch ('top', 'new', 'best', 'ask', 'show', 'job') * limit (optional number): Number of stories to fetch (max 100)
    • Returns: Array of story objects
  3. getStoryWithComments

    • Get a story along with its comment thread
    • Inputs: * id (number): Story ID
    • Returns: Story details with nested comments
  4. getCommentTree

    • Get the full comment tree for a story
    • Inputs: * storyId (number): ID of the story
    • Returns: Hierarchical comment tree structure
  5. getUser

    • Get a user's profile information
    • Inputs: * id (string): Username
    • Returns: User profile details including karma, created date, and about text
  6. getUserSubmissions

    • Get a user's submissions (stories and comments)
    • Inputs: * id (string): Username
    • Returns: Array of user's submitted stories and comments

Contributing

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a new Pull Request

License

This MCP server is licensed under the MIT License. See the LICENSE file for details.

About

This MCP server is built and maintained by devabdultech. It uses the official Hacker News API and Algolia Search API to provide comprehensive access to Hacker News data through the Model Context Protocol.

hn-mcp FAQ

How do I set up the hn-mcp server with Claude Desktop?
Add the hn-mcp configuration to your claude_desktop_config.json as documented, then run the server using npx commands.
Can hn-mcp provide real-time updates from Hacker News?
Yes, hn-mcp offers real-time access to Hacker News stories, comments, and user data through MCP.
What Hacker News data can hn-mcp access?
It can access stories by type, individual stories with comments, comment trees, user profiles, and user submissions.
Does hn-mcp support searching Hacker News content?
Yes, it uses Algolia's HN Search API to enable searching stories and comments.
Which LLM clients can integrate with hn-mcp?
hn-mcp integrates with any MCP-compatible LLM clients such as Cursor, Claude, and others supporting the protocol.
Is hn-mcp limited to specific story types?
No, it supports multiple story types including top, new, best, ask, show, and job stories.
How does hn-mcp handle user discussions?
It can fetch comment trees and user discussion threads to provide context-rich data for LLMs.