E-commerce in Elixir - pros and cons (vs Rails)

“5K users” is not much information, but I don’t imagine Phoenix would have any trouble serving that load on reasonable servers.

An alternative question: what are your requirements that preclude an off-the-shelf solution (like Spree etc) or even a hosted approach?

“Show products and let users buy them” is a pretty well-covered problem space, but it takes a lot of work to build a clean and consistent user experience - work that you might not want to do over again without a good reason.

I’m sorry for the misunderstanding - Its “5k users per month”, post edited

Answering your question - of-the-shelf solutions like Spree will cover my requirements, but… I will certainly try to make my own app :slight_smile:

Using what you already know is often a great choice.

I am not aware of any. As Elixir is much younger language with more niche community, I wouldn’t bet that there are any “big” products like these though at present.

1 Like

Not really. The Elixir community is well known to be upfront to tell when Elixir is not a good fit, and we have examples of that in this forum :slight_smile:

I am not aware of Spree, but Elixir already have some e-commerce stuff, and can be found on this forum:

Or this book by @shankardevy to build an e-commerce store form scratch:


LiveView is VERY FAR from being the biggest positive trait of Elixir.

Have you read on the OTP? The guarantees of a process being restarted if it crashes, for example?


That is so helpful, thank you all for your responses, I already have in mind some ideas, so thanks :slight_smile:

1 Like

As a matter of fact - yes, I have. The question was rather what other advantages Phoenix has over Ruby (or others langs) in building an e-commerce. I’m sorry if anyone misunderstood me… Thank you all for the replies, I already have my answers.

1 Like

Elixir/Phoenix is very good in building complex software systems.
See the talks of Sasa Juric (“Solid Ground”, “The Soul of Erlang and Elixir”) - these are a must see when you are looking into Elixir.
Or this talk, where Rich Hickey (creator of closure) tries to not promote Erlang (but does) The Language of the System - Rich Hickey - YouTube
When I look at Features - Spree Commerce - this is surely a complex software system.

On the other hand you’ll maybe want to communicate with 3rd parties (eg payment) or want to reuse sth for the CMS and so on. You’ll find more in Rails world for those.

But obviously you are doing this for fun, I’m sure you’ll have more of that using Elixir than Ruby.


Thanks you for the reply and sharing the materials,
Btw, yes, its for fun :slight_smile:

Best Regards

Hi YKostov.
I work in the ecommerce sector. You probably don’t know all aspects to cover in a ecommerce app.
The main function of an ecommerce is to sell, and for that a good user experiencie is required.
Other questions to consider:

  • CMS to edit pages and products or all by code?
  • Invoicing or stock control?
  • User portal to view your own orders or invoices?
  • How about SEO?
  • Cart management (i.e cart recovery)
  • time to market? (only one developer)
  • it’s easy to maintain and improve?
  • search integration (algolia, elasticsearch . . .)
  • and much more . . .

There are solucions already in place that already offer all of this, even in elixir we already have something.

That said, I would also like to have an ecommerce solution with elixir.

Maybe I would try to setup standalone modules, i.e the cart, search engine, etc.

It’s a hard work.



I am working in the Ecommerce area, with PHP and at the moment with the framework Shopware.
Had also thought for some time to program a prototype in Elixir, but as JuanjoA correctly described, the requirements are large. With such solutions as Shopware, for example, the extensibility with plugins is very important, both at the template level and the DB level or business logic level.

There were a few opensource beginnings in Elixir, but they all fell asleep again.


And there are probably one or two companies that have successfully used Elixir in this area, such as PepsiCo.
But these are certainly very adapted to their own requirements.

Best regards,


Hi I come from Rails and I’m building a kind of Shoppify clone with some custom things for my country, I’m convinced that Phoenix/Elixir was the right choice, It has every thing to create a E-Commerce site. I even had to create a electronic invoice using a P12 Certificate and I was able to do using erlang libraries (from elixir), Phoenix is amazing and with liveview complex interfaces was easy to do. An E-Commerce platform is a big thing you have orders, customers, inventories, shipping, etc. there are many things, but I feel that Phoenix/Liveview help a lot.

if it can help this is my current mix.ex

  defp deps do
      {:phoenix, "~> 1.5.8"},
      {:phoenix_ecto, "~> 4.2.1"},
      {:ecto_sql, "~> 3.5.4"},
      {:postgrex, ">= 0.15.8"},
      {:phoenix_html, "~> 2.14.3"},
      {:phoenix_live_reload, "~> 1.3.0", only: :dev},
      {:phoenix_live_dashboard, "~> 0.4.0"},
      {:telemetry_metrics, "~> 0.6.0"},
      {:telemetry_poller, "~> 0.4"},
      {:gettext, "~> 0.11"},
      {:jason, "~> 1.2.2"},
      {:plug_cowboy, "~> 2.4.1"},
      {:bcrypt_elixir, "~> 2.3.0"},
      {:ex_machina, "~> 2.7.0", only: :test},
      {:wallaby, "~> 0.28.0", runtime: false, only: :test},
      {:credo, "~> 1.5.5", only: [:dev, :test], runtime: false},
      {:git_hooks, "~> 0.5.2", only: [:test, :dev], runtime: false},
      {:phoenix_live_view, "~> 0.15.4"},
      {:floki, ">= 0.30.0", only: :test},
      {:cachex, "~> 3.3"},
      {:money, "~> 1.8.0"},
      {:liquex, "~> 0.5.0"},
      {:puid, "~> 1.0"},
      {:ecto_enum, "~> 1.4"},
      {:attrition, "~> 0.1.0"},
      {:poison, "~> 4.0"},
      {:geocoder, "~> 1.1.0"},
      {:countries, "~> 1.5"},
      {:mox, "~> 1.0", only: :test},
      {:struct_access, "~> 1.1"},
      {:bamboo, "~> 2.0.1"},
      {:bamboo_phoenix, "~> 1.0"},
      {:bamboo_ses, "~> 0.2.0"},
      {:grpc, "~> 0.3.1"},
      {:cowlib, "~> 2.8.1", hex: :grpc_cowlib, override: true},
      {:timex, "~> 3.7.3"},
      {:oban, "~> 2.5"},
      {:mimic, "~> 1.4", only: :test},
      {:excoveralls, "~> 0.14", only: :test},
      {:httpoison, "~> 1.8"}

One of my favorite lib is liquex Liquex — liquex v0.5.0 you can use liquid lang for your templates.



In an old reply I mentioned that I’m building a kind of shopify clone for my country, well… after some months working this is the result. the work is still in progress, so the answer is yes, you can build a e-comerce app in phoenix elixir :sunglasses:

My mix.exs updated

      {:phoenix, "~> 1.5.12"},
      {:phoenix_ecto, "~> 4.4.0"},
      {:ecto_sql, "~> 3.7.0"},
      {:postgrex, ">= 0.15.10"},
      # Needs to be updated to 3.0.0 but there are still conflicts with live_view
      {:phoenix_html, "~> 3.0.3"},
      {:phoenix_live_reload, "~> 1.3.3", only: :dev},
      {:telemetry_metrics, "~> 0.6.1"},
      {:telemetry_poller, "~> 0.4"},
      {:gettext, "~> 0.11"},
      {:jason, "~> 1.2.2"},
      {:plug_cowboy, "~> 2.5.1"},
      {:bcrypt_elixir, "~> 2.3.0"},
      {:ex_machina, "~> 2.7.0", only: :test},
      {:wallaby, "~> 0.28.1", runtime: false, only: :test},
      {:credo, "~> 1.5.6", only: [:dev, :test], runtime: false},
      {:git_hooks, "~> 0.6.3", only: [:test, :dev], runtime: false},
      {:phoenix_live_view, "~> 0.16.3"},
      {:floki, ">= 0.31.0"},
      {:cachex, "~> 3.4.0"},
      {:money, github: "elixirmoney/money", branch: "master"},
      {:liquex, "~> 0.6.1"},
      {:puid, "~> 1.0"},
      {:ecto_enum, "~> 1.4"},
      {:attrition, "~> 0.1.0"},
      {:poison, "~> 5.0.0"},
      {:struct_access, "~> 1.1"},
      {:bamboo, "~> 2.2.0"},
      {:bamboo_phoenix, "~> 1.0"},
      {:bamboo_ses, "~> 0.2.0"},
      {:timex, "~> 3.7.6"},
      {:oban, "~> 2.8.0"},
      {:mimic, "~> 1.5.0", only: :test},
      {:excoveralls, "~> 0.14.2", only: :test},
      {:httpoison, "~> 1.8"},
      {:slugify, "~> 1.3"},
      {:pdf, "~> 0.5.0"},
      {:elixir_xml_to_map, "~> 2.0"},
      {:barlix, "~> 0.6.1"},
      {:xml_builder, "~> 2.2"},
      {:mox, "~> 1.0", only: :test},
      {:premailex, "~> 0.3.13"},
      {:geocoder, "~> 1.1.3"}

I started as a CTO for www.amoi.no (and www.amoi.se) last wednesday and we’re an eCommerce using Elixir and liveview with sprinkles of Surface.

We’re pivoting to be a bit more api heavy, so most likely we will leave liveview out of it, but liveview was a great enabler to get the product off the ground quickly with a small and super senior / great team.

Not «eCommerce» in the traditional sense, as amoi is city-as-a-warehouse (for now) similar to what gojek etc do in asia, but we do logistics, payments and all that jazz.


well done mate, will test it for sure :slight_smile:

Do these websites have English versions? I was not able to quickly find it.

Not yet, we mostly have localized products for Norway and Sweden, but we plan to at least make menus and stuff into English not that long in the future :slight_smile:

Is your project open source?

not for now, it’s private but who knows in the future