+7
Daily
9,634
stars
445
forks
51
watchers
966
prs
625
issues
13
releases
README
Welcome to Loco
--
🚂 Loco is Rust on Rails.
--
English · 中文 · Français · Portuguese (Brazil) ・ 日本語 · 한국어 · Русский · Español · Vietnamese · العربية · Bahasa Indonesia
What's Loco?
Loco is strongly inspired by Rails. If you know Rails and Rust, you'll feel at home. If you only know Rails and new to Rust, you'll find Loco refreshing. We do not assume you know Rails.
For a deeper dive into how Loco works, including detailed guides, examples, and API references, check out our documentation website.
Features of Loco
Convention Over Configuration: Similar to Ruby on Rails, Loco emphasizes simplicity and productivity by reducing the need for boilerplate code. It uses sensible defaults, allowing developers to focus on writing business logic rather than spending time on configuration.
Rapid Development: Aim for high developer productivity, Loco’s design focuses on reducing boilerplate code and providing intuitive APIs, allowing developers to iterate quickly and build prototypes with minimal effort.
ORM Integration: Model your business with robust entities, eliminating the need to write SQL. Define relationships, validation, and custom logic directly on your entities for enhanced maintainability and scalability.
Controllers: Handle web requests parameters, body, validation, and render a response that is content-aware. We use Axum for the best performance, simplicity, and extensibility. Controllers also allow you to easily build middlewares, which can be used to add logic such as authentication, logging, or error handling before passing requests to the main controller actions.
Views: Loco can integrate with templating engines to generate dynamic HTML content from templates.
Background Jobs: Perform compute or I/O intensive jobs in the background with a Redis backed queue, or with threads. Implementing a worker is as simple as implementing a perform function for the Worker trait.
Scheduler: Simplifies the traditional, often cumbersome crontab system, making it easier and more elegant to schedule tasks or shell scripts.
Mailers: A mailer will deliver emails in the background using the existing loco background worker infrastructure. It will all be seamless for you.
Storage: In Loco Storage, we facilitate working with files through multiple operations. Storage can be in-memory, on disk, or use cloud services such as AWS S3, GCP, and Azure.
Cache: Loco provides an cache layer to improve application performance by storing frequently accessed data.
So see more Loco features, check out our documentation website.
Getting Started
--
sh
cargo install loco
cargo install sea-orm-cli Only when DB is needed
--
Now you can create your new app (choose "SaaS app").
--
sh
❯ loco new
✔ ❯ App name? · myapp
✔ ❯ What would you like to build? · Saas App with client side rendering
✔ ❯ Select a DB Provider · Sqlite
✔ ❯ Select your background worker type · Async (in-process tokio async tasks)
🚂 Loco app generated sucTop issues
#1714Contribute rhai-loco to this org21 comments · 2025-12-22#1856Admin dashboard11 comments · 2026-10-13#1859Unmaintained unsafe-libyaml (RUSTSEC-2024-0449) via serde_yaml_ng and loco-gen/rrgen3 comments · 2026-10-16#1766Rails style migrations3 comments · 2026-05-13#1893Web site documentation is hard to read | Make it more readable (suggestion and idea)1 comments · 2026-10-30#1720Support having custom field types on models when using entity generation1 comments · 2025-12-31#1905Db seed0 comments · 2026-11-14#1904CI: pin actions to commits, add coverage and security checks, and run zanadir0 comments · 2026-11-14
Discussions
#1888Guest article idea: Testing an agent-facing Loco endpoint0 comments · 2026-10-24#1836Loco 1.2.00 comments · 2026-09-24#1833Onboard experience0 comments · 2026-09-21#1796VSCode Snippets Extension for Rust Loco0 comments · 2026-08-03#1793Migration of PKs to 1.01 comments · 2026-08-02#1781No new updates?1 comments · 2026-07-25#1769How to run the app from another dir other than root working directory?1 comments · 2026-05-29#1765Plan for Next Release?1 comments · 2026-05-05
Latest release
v1.3.1 v1.3.1 2026-11-06Fixed - SQLite apps could fail to boot with PoolTimedOut. 1.3.0 runs the PRAGMAs on every new connection, and some of them read the database file, so opening a connection waits on any other connection's lock for up to busy_timeout. That wait counted against connect_timeout (500ms in generated test configs), so a busy file failed boot instead of waiting. SQLite pools now allow busy_timeout on top of the acquire timeout. Seen as intermittent test failures, mostly on CI and Windows.