Cadditor — a minimal web editor for Caddyfile
Hi everyone,
I use Caddy in my homelab, and one of the things I like most about it is how simple the Caddyfile syntax is.
For me, the configuration format itself was never the problem. The friction was the workflow around making a small change:
SSH → edit → format → verify → reload
I looked at existing Caddy web interfaces, but most of them solve a much broader problem: dashboards, monitoring, health information, form-based configuration, multiple instances, and so on.
Those are useful features, but for my homelab I wanted something much smaller.
I wanted to keep using the Caddyfile directly and only remove the repetitive work around editing and applying it.
So I built Cadditor.
Cadditor is a small web application served by Caddy itself. It provides a browser-based editor for the actual Caddyfile, with:
-
Caddyfile syntax highlighting
-
code folding
-
indicators for changed lines
-
formatting before apply
-
configuration verification
-
reload only after verification succeeds
The main design principle is that the Caddyfile remains the source of truth.
Cadditor does not generate another configuration format and does not try to turn Caddy into a form-based GUI.
I also wanted the application itself to stay small. I run Caddy in an Alpine LXC, so I did not want to add Docker, Node.js or another application runtime just for the editor.
Caddy serves the frontend, while the backend consists of small CGI scripts behind fcgiwrap.
Installation, updates and removal are handled by a shell installer. Cadditor’s internal Caddy configuration lives in its own imported snippet, while the actual Caddyfile remains user-owned.
I built it for my own homelab, but I am quite happy with how it turned out, so I have published the first release.
If you prefer working directly with Caddyfiles and have a similar use case, I would be very interested in feedback.
GitLab:
Live demo:
The demo uses the real Cadditor frontend. Since it runs as a static GitLab Page, it cannot actually run Caddy formatting, verification or reload.
AI disclosure:
I used ChatGPT throughout the project as a development assistant for architecture discussions, implementation support, code review, documentation and writing assistance. I made the product and architecture decisions, reviewed and tested the resulting implementation, and maintain the project.