Is Elixir or Common Lisp the best language for building a bootstrapped B2B SaaS in 2024?
Tags: lisp, commonli, elixir, python
Published: 2024-03-02 17:27:05

There was this article and discussion on Lobster last month.

- https://lobste.rs/s/ysam1j/why_elixir_is_best_language_for_building 

I'll give you the key takeaway right now:

> the best language/tooling to start a SaaS with is the one you already know.

Now let's discuss some more.

[![](https://camo.githubusercontent.com/fe32e3bd79cdc3fe2be4c71cc89bb0515215a6393c3ea1aa18b0501d1f6b5755/687474703a2f2f692e696d6775722e636f6d2f6f4f326d7572712e706e67 "A metrics dashboard for your Common Lisp web server. What I want though is a Django-like database interface")](https://github.com/deadtrickster/prometheus.cl)

**I want to be convinced and find the Graal, but I’m still torn between Python, and now Common Lisp.** When I take a look to maybe rewrite my Python/Django app to Elixir, **I miss stuff:** no **admin dashboard** (unless you pay 300USD), no automatic **DB migrations** unlike Django and CL’s Mito (yet I don’t have Ecto experience so maybe it’s a non issue) (I've been point to [Ecto migrations](https://hexdocs.pm/ecto_sql/Mix.Tasks.Ecto.Gen.Migration.html), that's a valid point), **a lot of code generation** (they rot, don’t they?)… 

**LiveView?** I can use **HTMX**, its **websockets extension**, Unpoly, and they are cross-stack. **No compile-time type checks**, like Python, unlike CL; a **deployment** story in-between Python (dangerous) and CL (build and send a binary) and, because I am now spoiled with CL’s richness of image-based **interactive features**, I see much less of them in Elixir (no “compile this function ad get warnings”). And oh, there’s some **syntax** to pay attention to again, those { % => etc. Elixir’s Emacs modes don’t look good when Slime or Sly offer a ton of features. With Elixir I’m back at the **terminal** which feels like a regression. 

I’m spoiled.

So, is Elixir really the best language for building a bootstrapped SaaS? Python/Django, I admit, despite their flaws, have arguments. For a solo developer, Common Lisp is hyper productive. Its web offering is minimal but if you know the web, plug in a DB, HTMX, a login system and you’re on tracks. CL won’t have shiny dashboards ([wait, does it](https://github.com/40ants/prometheus-gc)? Grafana dashboard for SBCL and Hunchentoot: memory, threads, requests per second, GC state…) and a supervision tree (only ruricolist/moira to monitor and restart background threads), but you can get a GenServer-inspired actor library (mdbergmann/sento), and I believe they share runtime features: efficiency, live reload is doable. Last but not last, CL is maybe easier to use for other tasks: ingest data efficiently (SBCL is fast), small-ish binaries, scripts (now easier with my CIEL helper).

Elixir is absolutely more shiny and enterprise ready and I don’t know what I miss, but there’s nothing ideal for a rewrite…

Now, after this comment of mine I've been pointed to [Torch](https://github.com/mojotech/torch) and Ecto's Gen.Migration, the two looking super useful. Good points. I also started to write my CRUD admin dashboard for Common Lisp, let's see how this goes…