hn-server logo

hn-serverHacker news MCP server

(0)
Daniel NikulshynReviewed by Daniel Nikulshyn·Updated July 2026

Overview

hn-server is a Model Context Protocol (MCP) server that provides tools for fetching stories from Hacker News. This server parses the HTML content from news.ycombinator.com and provides structured data for different types of stories (top, new, ask, show, jobs). The server features include fetching different types of stories, getting structured data including titles, URLs, points, authors, timestamps, and comment counts, and configurable limit on the number of stories returned. It also includes clean error handling and validation. To use this server, users must clone the repository, install dependencies, and build the server. The server can then be used with tools like Claude by configuring the MCP server in the settings and using natural language interface to interact with Hacker News. The server is built using TypeScript, the Model Context Protocol SDK, Axios for HTTP requests, and Cheerio for HTML parsing. It includes robust error handling for various scenarios such as invalid story types, network failures, HTML parsing errors, and invalid parameter values.

Key features

  • Fetch different types of stories (top, new, ask, show, jobs)
  • Get structured data including titles, URLs, points, authors, timestamps, and comment counts
  • Configurable limit on number of stories returned
  • Clean error handling and validation
  • Integration with Claude for natural language interface

Pricing

Model
Free
Category
MCP Servers
Rating
No reviews yet

Use cases

Fetching Top Stories

Use the get_stories tool to fetch the top 5 stories from Hacker News, including titles, URLs, points, authors, timestamps, and comment counts.

Interacting with Claude

Configure the hn-server with Claude to interact with Hacker News using natural language, such as 'Show me the top 5 stories from Hacker News' or 'What are the latest Ask HN posts?'.

Pros & Cons

Pros

  • Provides structured data for different types of Hacker News stories
  • Configurable limit on the number of stories returned
  • Robust error handling and validation
  • Integrates with Claude for natural language interaction

Cons

  • Requires technical setup and configuration
  • Limited to fetching stories from Hacker News

Reviews

Sign in to leave a review.

No reviews yet. Be the first!

Q&A

Does hn‑server support other platforms besides Claude?

The server exposes a standard MCP interface, so any tool that can consume MCP endpoints—including other AI assistants—can integrate with it.

Asked by Ludovic Girard · Mar 3, 2026

What data fields does hn‑server provide for each story?

Each story includes its title, URL, points, author, timestamp, and comment count, all returned in structured JSON for easy consumption.

Asked by Bruno Kaufmann · Feb 22, 2026

Can I limit how many stories the server returns?

Yes, the server allows you to set a configurable limit on the number of stories returned for each request, giving you control over the payload size.

Asked by Jovana Petrovic · Jan 1, 2026

How do I deploy hn‑server to start fetching Hacker News stories?

Clone the GitHub repo, install dependencies via your package manager, then build and run the server. Once running, configure the MCP endpoint in your client (e.g., Claude) to use the server.

Asked by Idris Suleiman · Dec 10, 2025

Ask a question

MCP Servers alternatives