Lean CMS is a Rails 8 engine for marketing sites. Editors hover over any page section to edit it in place. Developers wire content into their own ERB templates and stay in control of the design.
Marketing sites are read-heavy and design-driven. Lean CMS optimizes for both — without taking your layout hostage or running its own database server.
Editors hover over any page section to reveal an Edit overlay. No back-and-forth between admin and live preview — the live page is the editor.
Lean CMS provides helpers to pull content into your ERB templates. It never injects a theme, never wraps your markup, never owns your layout.
No database server to run, no add-on bill. A single file deployable with Kamal — production-ready for marketing sites at any reasonable scale.
Editors don't context-switch into a separate admin to make a change. They click directly on the text, image, or section overlay — and a focused editor appears, right where the content lives.
Drop helpers into your views. Logged-in editors get an overlay; visitors see plain, unwrapped HTML.
<%# A hover-editable section %> <%= cms_editable_section(page: "home", section: "hero") do %> <section class="hero"> <h1><%= editable_content("hero", "heading") %></h1> <p><%= editable_content("hero", "subhead") %></p> <% bg = page_content_image_url(@page, "hero", "bg") %> <% if bg %> <%= image_tag bg, class: "absolute inset-0" %> <% end %> </section> <% end %> <%# Optimized responsive image, gem-managed %> <%= lean_cms_picture_tag "hero", alt: "Hero photo", widths: [640, 1280], sizes: "(min-width: 768px) 50vw, 100vw" %>
Every helper does one obvious thing. You can read the source of every public method in five minutes.
<picture> with WebP+fallback
text, rich text, image, boolean, url, color, dropdown, cards, bullets.
Login, password reset, magic-link invitations. Mounted at /lean-cms/login.
Every content change tracked via PaperTrail. One-click undo on inline edits.
Rake task that emits WebP + JPG fallback variants at multiple widths.
Granular permission flags: pages, blog, users, settings. Plus super admin.
Pull production content locally to stage changes; deploy via migrations.
Define forms in YAML; submissions land in the admin with email notifications.
Declare pages, sections, fields in config/lean_cms_structure.yml; seed in one task.
Lean CMS today is a Rails engine you drop into an app. The plan is to grow into a full app generator and, eventually, a hosted site-builder service.
In-context editing, auth, content types, image optimization in any Rails 8 app.
lean_cms new my-site --structure=site.yml — full Rails app from a YAML spec.
Intake form → AI-generated YAML → app generation → Kamal deploy to a fresh droplet.
From bundle install to /lean-cms/login in under a minute.