---
title: "Deploy Postgres HTTP"
description: "Turns your postgres db into an REST api"
category: "Other"
url: https://railway.com/deploy/UYtPO2
---

# Deploy Postgres HTTP

Turns your postgres db into an REST api

**[Deploy Postgres HTTP on Railway](https://railway.com/template/UYtPO2)**

- **Creator:** lasse's Projects
- **Category:** Other
- **Total deploys:** 7

## Template content

### Postgres HTTP

- **Image:** lassejlv/postgres_http:latest
- **Public domain:** Yes

### Postgres https://devicons.railway.app/i/postgresql.svg

- **Image:** ghcr.io/railwayapp-templates/postgres-ssl:16

## Documentation

# Postgres HTTP

Turns your postgres db into an http server. Great for beginners or just small projects and testing.

You can find the source code here: github.com/lassejlv/postgres_http

## API reference

```bash
- POST /query
  - body: { query: string, args: any[] }
  - headers: { Authorization: Bearer  }
  - response: { rows: any[] }

- GET /status
   - headers: { Authorization: Bearer  }
   - response: { ok: boolean, ping: number  }
```

## I cant run...

By default you cannot run: `DELETE, DROP, TRUNCATE`.
Update the env variable `ALLOW_DANGEROUS_SQL_COMMANDS` and set it to true if you wanna be doing that.

 ## API key
You will find the api under the variables tab. It's randomly generated under creation.

## 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/UYtPO2
