Server for PostgreSQL icon

Server for PostgreSQL

在菜单栏一键启动、停止、重启 PostgreSQL

Start, stop, and restart PostgreSQL server right from your menu bar

核心功能

Features

一键启停

One-Click Control

菜单栏点击即可启动、停止、重启 PostgreSQL 服务(默认端口 5432)。

Start, stop, or restart PostgreSQL with a single click from the menu bar (default port 5432).

端口自动避让

Port Auto-Avoidance

优先使用配置文件中用户指定的端口;若该端口被占用,自动从操作系统获取一个随机空闲端口,无需手动干预。

Prefer the user-specified port in the config file. If it is occupied, automatically allocate a random free port from the OS — no manual intervention needed.

仅本地访问

Local Access Only

默认开启,仅允许本机访问;可关闭限制可供局域网设备访问,点击后服务自动重启生效。

Restrict connections to localhost (127.0.0.1) with one toggle; the service restarts automatically after switching.

开机自启动

Launch at Login

支持开机后自动启动应用,保持 PostgreSQL 服务随时可用。

Automatically launch the app when you log in to macOS so PostgreSQL is always ready.

一键复制连接 URI

Copy Connection URI

点击菜单栏端口项,即可复制 postgresql://127.0.0.1:XXXXX 连接串。

Click the port item to copy the postgresql://127.0.0.1:XXXXX connection string.

工作目录快捷访问

Working Directory Access

一键打开包含数据文件、日志、配置与 PostgreSQL 程序的工作目录。

Quickly open the working directory containing data, logs, config, and PostgreSQL binaries.

实时状态指示

Live Status Indicator

菜单栏图标通过透明度直观显示服务运行状态。

The menu bar icon visually reflects the running state through opacity.

无数据收集

No Data Collection

完全在本地运行,不连接任何远程服务器,不收集任何用户数据。

Runs entirely on your machine. No remote servers, no data collection.

使用方式

How to Use

点击菜单栏中的应用图标打开菜单
点击 Start 启动 PostgreSQL 服务(首次启动自动初始化数据目录与配置)
点击 Stop 停止服务,Restart 重启服务
点击 Port: XXXXX 复制 PostgreSQL 连接 URI
开启 Local Access Only 限制仅本机访问,切换后服务会自动重启
Click the app icon in the menu bar to open the menu
Click Start to launch PostgreSQL (first launch auto-initialises the data directory and config)
Click Stop to stop, Restart to restart
Click Port: XXXXX to copy the connection URI
Enable Local Access Only to restrict to localhost — the service restarts automatically

常见问题

FAQ

PostgreSQL 无法启动?
退出程序后,通过 Working Directory 打开工作目录,删除 Server for PostgreSQL 文件夹(注意备份配置文件和日志),然后重启程序,或者查看 logs/ 下的日志确认具体原因。
连接被拒绝?
确认服务已启动,检查浏览器访问的端口是否与菜单中显示的端口项一致,确认 Local Access Only 状态是否与当前所需的访问状态一致,确认防火墙是否允许该端口的访问。
实际端口与我配置文件里的不一样?
配置文件中的端口被占用时,应用会临时切换到下一个可用端口(菜单中端口前会出现 ⚠ 告警),下次重新启动仍会优先尝试您配置的端口。如需使用配置文件中的端口访问,请先确定配置文件中的端口是否被占用,解决端口占用问题之后重启软件即可。
开启 Local Access Only 后局域网其他设备无法连接?
这是预期行为,该选项仅允许本机 127.0.0.1 访问。如需局域网访问,请关闭该选项,服务会自动重启并绑定 0.0.0.0。
PostgreSQL won't start?
Check whether a port near 5432 is already in use — the app auto-avoids. Also inspect the logs via the Working Directory for the exact reason.
Connection refused?
Make sure the service is running (icon is fully opaque) and the port you are connecting to matches the finalPort shown in the menu bar.
Why is the actual port different from what's in my config file?
When your configured port is occupied, the app temporarily switches to the next free one (a ⚠ appears before Port in the menu). This is never written back to the config — the next launch will still prefer your configured port first.
Can't connect from the LAN after enabling Local Access Only?
This is expected — the option binds to 127.0.0.1 localhost only. Disable it to allow LAN access; the service restarts automatically bound to 0.0.0.0.