Back to MCP Catalog

Hacker News MCP Server

News & InformationTypeScript
Access and retrieve stories from Hacker News
Available Tools

get_stories

Fetches stories from Hacker News based on type and limit parameters

typelimit

A Model Context Protocol server that provides structured access to Hacker News content. This server parses HTML content from news.ycombinator.com and delivers organized data for different types of stories including top, new, ask, show, and jobs posts. It enables AI assistants to retrieve current tech news and discussions with metadata like points, authors, and comment counts.

Installation

  1. Clone the repository:
git clone https://github.com/pskill9/hn-server
cd hn-server
  1. Install dependencies:
npm install
  1. Build the server:
npm run build
  1. Configure the MCP server in your AI assistant's settings.

Configuration

The server needs to be added to your AI assistant's MCP configuration. The exact location depends on your system:

  • For Claude desktop app (macOS): ~/Library/Application Support/Claude/claude_desktop_config.json
  • For Claude desktop app (Windows): %APPDATA%\Claude\claude_desktop_config.json
  • For VSCode Claude extension: Add to VSCode Settings JSON

Usage

Once configured, you can interact with the Hacker News MCP server using natural language. Examples:

  • "Show me the top 5 stories from Hacker News"
  • "What are the latest Ask HN posts?"
  • "Get me the top Show HN submissions from today"

The server will fetch the requested stories and return them in a structured format with titles, URLs, points, authors, timestamps, and comment counts.

Story Types

The server supports different types of Hacker News stories:

  • Top stories (default)
  • New stories
  • Ask HN posts
  • Show HN submissions
  • Job listings

Limitations

  • The server can return a maximum of 30 stories per request
  • The data is fetched in real-time from Hacker News, so results depend on the current state of the site
  • Some stories may not have all fields populated (e.g., text posts won't have external URLs)

Related MCPs

No related MCPs found

About Model Context Protocol

Model Context Protocol (MCP) allows AI models to access external tools and services, extending their capabilities beyond their training data.

Generate Cursor Documentation

Save time on coding by generating custom documentation and prompts for Cursor IDE.