---
title: "Installation and Setup"
description: "Hono is a web framework built on Web Standards. Because it is designed to run on any JavaScript runtime, you can install it using your favorite package manager and deploy your application across mu..."
last_updated: "2026-11-24T23:01:51.035909+00:00"
canonical_url: "https://www.doc0.dev/docs/552ca36e-f67e-41c3-a07a-def9bd9551b0/user-guide/installation-and-setup"
---

## Overview

Hono is a web framework built on Web Standards. Because it is designed to run on any JavaScript runtime, you can install it using your favorite package manager and deploy your application across multiple environments including Node.js, Deno, Bun, Cloudflare Workers, AWS Lambda, Vercel, and Netlify.

This guide covers how to install Hono and launch your first application across different runtimes using its public API.

---

## Installation

You can install Hono using npm, yarn, pnpm, bun, or deno.

```bash
# Using npm
npm install hono

# Using yarn
yarn add hono

# Using pnpm
pnpm add hono

# Using bun
bun add hono
```

For Deno, you can import Hono directly from the JSR registry:

```typescript
import { Hono } from 'jsr:@hono/hono'
```

---

## Launching Your First Application

### Basic Application Setup

To create a basic Hono application, instantiate the `Hono` class, define your routes using HTTP method functions such as `app.get()`, and return responses using helper methods like `c.text()` or `c.json()`.

```typescript
import { Hono } from 'hono'

const app = new Hono()

app.get('/', (c) => c.text('Hello!'))

export default app
```

### Runtime Adapters and Entry Points

Depending on the runtime environment where your application executes, you may need specific entry points or handlers to interface incoming requests with Hono's `.fetch()` method.

The table below lists the available runtime integration modules and supported adapters.

| Integration / Runtime | Module Import Path | Primary Helper / Handler |
| :--- | :--- | :--- |
| **Cloudflare Workers** | `hono/cloudflare-workers` | `upgradeWebSocket`, `getConnInfo`, `serveStatic` |
| **Cloudflare Pages** | `hono/cloudflare-pages` | `handle`, `handleMiddleware`, `serveStatic` |
| **Deno** | `hono/deno` | `upgradeWebSocket`, `getConnInfo`, `serveStatic`, `toSSG` |
| **Bun** | `hono/bun` | Runtime-native `app.fetch` |
| **AWS Lambda** | `hono/aws-lambda` | `handle`, `streamHandle`, `getConnInfo` |
| **Vercel** | `hono/vercel` | `handle`, `getConnInfo` |
| **Netlify** | `hono/netlify` | `handle` |
| **Lambda@Edge** | `hono/lambda-edge` | `handle`, `getConnInfo` |
| **Service Worker** | `hono/service-worker` | `fire`, `handle` |

> [!TIP]
> You can detect your running environment programmatically using `getRuntimeKey()` from `hono/adapter`.
>
> **Supported runtime keys:** `node`, `deno`, `bun`, `workerd`, `fastly`, `edge-light`, `other`  
> *(Sources: `src/helper/adapter/index.ts`)*

---

## Examples by Runtime

### 1. Cloudflare Workers
Cloudflare Workers execute Hono directly via the exported fetch handler or module worker default export.

```typescript
import { Hono } from 'hono'
import { getRuntimeKey } from 'hono/adapter'

const app = new Hono()

app.get('/', (c) => c.text(`Hello from ${getRuntimeKey()}`))

export default app
```

### 2. AWS Lambda
Use the `handle` function from `hono/aws-lambda` to convert your Hono application into an AWS Lambda handler compatible with API Gateway, Application Load Balancers (ALB), and Function URLs.

```typescript
import { Hono } from 'hono'
import { handle } from 'hono/aws-lambda'

const app = new Hono()

app.get('/', (c) => c.text('Hello from Lambda'))

export const handler = handle(app)
```

### 3. Vercel
Vercel serverless functions consume the `handle` wrapper from `hono/vercel`.

```typescript
import { Hono } from 'hono'
import { handle } from 'hono/vercel'

const app = new Hono()

app.get('/', (c) => c.text('Hello from Vercel'))

export default handle(app)
```

### 4. Netlify
Netlify serverless functions integrate using the `handle` utility from `hono/netlify`.

```typescript
import { Hono } from 'hono'
import { handle } from 'hono/netlify'

const app = new Hono()

app.get('/', (c) => c.text('Hello from Netlify'))

export default handle(app)
```

## Related

- [Routing and Handlers](https://www.doc0.dev/docs/552ca36e-f67e-41c3-a07a-def9bd9551b0/user-guide/routing-and-handlers)
- [Runtime Adapters (User guide)](https://www.doc0.dev/docs/552ca36e-f67e-41c3-a07a-def9bd9551b0/user-guide/runtime-adapters-guide)


## Sitemap

See the full [sitemap](https://www.doc0.dev/docs/552ca36e-f67e-41c3-a07a-def9bd9551b0/llms.txt) for all pages in this wiki.
