Short startup path
Favor a thin request lifecycle, modest dependencies, and predictable per-request work so CGI startup stays practical.
Mojito is for the places where Perl CGI is still the practical deployment target: shared hosting, tiny utilities, internal tools, and small sites where every request may be competing for memory and CPU.
Independent project. Heavily influenced by the excellent ideas, ergonomics, and cooking of Mojolicious. Mojito is not affiliated with the Mojolicious project.
Before choosing Mojito
Mojolicious is the broader, mature, full-featured Perl web framework. It gives you the modern application runtime, built-in servers, WebSockets, a rich toolkit, plugins, testing support, and room to grow. CGI support exists there too, but it is understandably not the center of the architecture.
Mojito exists for the narrower edge case: a shared host gives you cgi-bin, persistent services are unavailable or undesirable, resources are tight, and you still want pleasant Perl web-development patterns.
Made for constraints
Mojito treats process startup, memory use, CPU contention, filesystem access, and repeat work as first-class design constraints instead of pretending a shared server behaves like a dedicated application host.
Favor a thin request lifecycle, modest dependencies, and predictable per-request work so CGI startup stays practical.
Designed for very small shared servers where your process may be fighting many neighbors for memory and CPU attention.
Avoid repeating expensive work. Cache configuration, rendered output, lookups, and other safe reusable results where the CGI lifecycle allows it.
Start with login, logout, protected dashboard flow, sessions, and the wiring developers usually have to build before the real application begins.
Routes, rendering, helpers, responses, and developer ergonomics are shaped by lessons from Mojolicious wherever they make sense for CGI.
Designed for ordinary cgi-bin deployment where a daemon, reverse proxy configuration, containers, or root access may simply not be available.
Useful on request one
A new Mojito application can start with the basic authenticated application shape already present: login, logout, a protected dashboard, session handling, and extension points for your own users, roles, and application rules.
The goal is not to prescribe your product. It is to remove repetitive plumbing so your first changes can be the parts that make your application yours.
A clean starting flow you can connect to your own user store.
A protected route and page that demonstrates authenticated application structure.
Session teardown is part of the scaffold instead of an afterthought.
Tiny by intent
The API can feel modern without pretending CGI is an application server. Mojito keeps the boundary visible and tries to make the common path cheap.
#!/usr/bin/env perl
use v5.26;
use Mojito;
get '/' => sub ($c) {
$c->render(text => 'Fresh CGI. Modern Perl.');
};
app->run;
The decision rule
Persistent runtime available? Need richer real-time capabilities, broader tooling, or a full modern framework? Go here.
Perl CGI, tiny memory budget, busy shared CPU, server-rendered HTML, and a desire to ship without running a daemon.
Choose the narrow tool on purpose
Start small, inherit an authentication-shaped application, cache safe repeated work, and keep the request path lean. When the application outgrows CGI, that is a good day: graduate to Mojolicious or another full application framework.