> ## Documentation Index
> Fetch the complete documentation index at: https://bun.manicule.dev/llms.txt
> Use this file to discover all available pages before exploring further.
> For every page in one file, fetch https://bun.manicule.dev/llms-full.txt (large).
> To search and read these docs as tools, connect the MCP server at https://bun.manicule.dev/api/mcp.
> Every agent surface: https://bun.manicule.dev/.well-known/llms-manifest.json

# Streaming HTTP Server with Node.js Streams (/guides/http/stream-node-streams-in-bun)

<!-- agent-signals: reading_time_min: 1 · est_tokens: 149 · updated: 2026-08-02 -->
Related: [Common HTTP server usage](/guides/http/server.md), [Write a simple HTTP server](/guides/http/simple.md), [Send an HTTP request using fetch](/guides/http/fetch.md), [Hot reload an HTTP server](/guides/http/hot.md), [Start a cluster of HTTP servers](/guides/http/cluster.md), [Configure TLS on an HTTP server](/guides/http/tls.md)

In Bun, a [`Response`](https://developer.mozilla.org/en-US/docs/Web/API/Response) accepts a Node.js [`Readable`](https://nodejs.org/api/stream.html#stream_readable_streams) as its body.

This works because Bun's `Response` accepts any async iterable as its body, and Node.js streams are async iterables.

```ts icon="/icons/typescript.svg" title="server.ts"
import { Readable } from "stream";
import { serve } from "bun";
serve({
  port: 3000,
  fetch(req) {
    return new Response(Readable.from(["Hello, ", "world!"]), {
      headers: { "Content-Type": "text/plain" },
    });
  },
});
```
