---
title: "Deploy Clove"
description: "A Claude.ai reverse proxy"
category: "Other"
url: https://railway.com/deploy/clove
---

# Deploy Clove

A Claude.ai reverse proxy

**[Deploy Clove on Railway](https://railway.com/template/clove)**

- **Creator:** Muhammad Bilal
- **Category:** Other

## Template content

### Clove

- **Image:** mirrorange/clove:latest
- **Public domain:** Yes

## Documentation

# Deploy and Host Clove on Railway

Clove is an all-in-one Claude reverse proxy tool designed to provide standard API access to Claude.ai. It features dual-mode operation supporting both OAuth authentication (via Claude Code API) and web proxy mode. It offers high compatibility with Claude API clients, a user-friendly web management interface, automatic authentication switching, and built-in quota tracking.

## About Hosting Clove

When deploying Clove on Railway, Railway hosts the containerized Clove application service based on its official Docker image. Railway manages the underlying infrastructure, providing seamless container deployment, continuous operation, and automatic HTTPS endpoint provision through HTTP proxy networking.

Clove requires persistent storage mounted to `/app/data` to retain configuration files, API key records, and user session information across deployments or system restarts. Networking is simplified as Railway automatically routes external traffic to the container's exposed internal web port. Clove functions as a lightweight service, allowing easy scaling of memory and CPU resources directly from the Railway dashboard as request volumes grow.

## Common Use Cases

* **API Proxy for Claude Services**: Standardizing Claude.ai web access or OAuth logins into OpenAI/Claude-compatible API endpoints for local LLM tools and integrations.
* **API Key & Quota Management**: Managing multi-account Claude credentials, tracking usage, and issuing individual application API keys for team members or personal projects.
* **Unified Claude Access**: Consolidating multiple Claude access methods into a single, reliable web service with automated switching.

## Dependencies for Clove Hosting

| Dependency | Purpose | Required |
| --- | --- | --- |
| Railway Volume | Persistent storage for configuration (`/app/data`) | Yes |
| Claude Account Credentials / Session Cookie | Authentication with Claude backend services | Yes |

### Deployment Dependencies

| Resource | Link |
| --- | --- |
| Docker Hub Image | [mirrorange/clove](https://hub.docker.com/r/mirrorange/clove) |


### Implementation Details

#### Docker

Clove is deployed using its official prebuilt Docker image:

`mirrorange/clove:latest`

Railway pulls and deploys this image directly without requiring custom build scripts.

#### Public Networking

| Setting | Value |
| --- | --- |
| Proxy Type | HTTP Proxy |
| Target Port | 5201 |

To make the service publicly accessible, generate a domain under the Railway project settings for the Clove service.

#### Environment Variables

| Variable | Required | Description |
| --- | --- | --- |
| `PORT` | Yes | The internal network port the service listens on (Default: `5201`). |
| `ADMIN_API_KEYS` | Optional | Custom admin access key for the Clove management panel. Auto-generated if not specified. |
| `BASE_URL` | Optional | The external domain or base URL assigned to your Railway deployment. |
| `DEFAULT_MODEL` | Optional | Default model used for processing requests (Default: `claude-sonnet-4-20250514`). |
| `LOCALE` | Optional | UI language setting for the management panel (Default: `zh`). |
| `LOG_LEVEL` | Optional | Logging verbosity (Default: `INFO`). |
| `REQUEST_TIMEOUT` | Optional | HTTP request timeout in seconds (Default: `300`). |
| `STREAM_TIMEOUT` | Optional | Streaming response timeout in seconds (Default: `300`). |
| `COOKIES` | Optional | Claude.ai session cookies for web proxy mode. |

Example Raw Editor format for Railway Variables:

```env
PORT=5201
ADMIN_API_KEYS=your-secure-admin-key
BASE_URL=https://your-railway-domain.up.railway.app
DEFAULT_MODEL=claude-sonnet-4-20250514
LOCALE=zh
LOG_LEVEL=INFO
REQUEST_TIMEOUT=300
STREAM_TIMEOUT=300

```

#### Persistent Storage

Clove requires persistent volume storage to prevent losing user sessions, accounts, and generated API keys when the deployment updates or restarts.

1. Open the **Clove Service** in your Railway dashboard.
2. Go to **Settings** → **Volumes**.
3. Click **Add Volume**.
4. Set the Mount Path to:

```text
/app/data

```

#### Database

No external database service (such as PostgreSQL or Redis) is required. Data persistence is handled internally via local file storage under the `/app/data` volume mount.

#### Build & Start

No custom build or start commands are required. The image handles runtime startup automatically on port `5201`.

#### Accessing the Application

1. In Railway, go to **Service Settings** → **Networking** and click **Generate Domain**.
2. Open your web browser and navigate to the generated public URL.
3. Access the admin dashboard using the `ADMIN_API_KEYS` set in your environment variables (or check deployment logs if left to auto-generate).
4. Add your Claude credentials in the management interface and generate client API keys for your applications.

## Why Deploy Clove on Railway?

Railway provides a seamless platform for deploying and scaling web applications. With automated deployments from GitHub, instant persistent storage attachment, easy environment variable management, and default HTTPS routing, hosting your applications on Railway ensures reliable performance and operational simplicity.

## Similar templates

- [Rocky Linux](https://railway.com/deploy/rocky-linux) — [Jul'26] Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀
- [Foundry Virtual Tabletop](https://railway.com/deploy/X5tR6G) — A Self-Hosted & Modern Roleplaying Platform
- [Letta Code Remote](https://railway.com/deploy/letta-code-remote) — Run a Letta Code agent 24/7. No inbound ports, just deploy.

Open this page in a browser: https://railway.com/deploy/clove
