Installing Elixir with ASDF

Published: (April 30, 2026 at 11:22 PM EDT)
2 min read
Source: Dev.to

Source: Dev.to

I’m getting into Elixir, but before I could start doing anything I had to install it. Since I use asdf to manage language versions, I wrote down how I did it on my machine.

For those who don’t know, Elixir is an open‑source, modern, dynamic and functional language created by José Valim. It runs on the Erlang VM, known for low‑latency, concurrent, fault‑tolerant, distributed and scalable systems.

Install asdf

Follow the tutorial on the official page:

Install asdf‑vm

Erlang dependencies

Before installing Erlang you need a few system packages.

# macOS
brew install autoconf
# Ubuntu / Debian
sudo apt-get -y install build-essential autoconf m4 libncurses5-dev \
    libwxgtk3.0-dev libgl1-mesa-dev libglu1-mesa-dev libpng-dev \
    libssh-dev unixodbc-dev xsltproc fop

Other operating systems can use Docker or pre‑built binaries. See the official guide for more options.

Install Erlang

# Add the Erlang plugin (all available versions)
asdf plugin-add erlang

# List all available Erlang versions
asdf list-all erlang

# Install a specific version (e.g., 22.2.2)
asdf install erlang 22.2.2

# Set it as the global version
asdf global erlang 22.2.2

Note: The Erlang version is often referred to as the OTP version. The Elixir version you install must be compiled for the same OTP version.

You can verify the installed OTP version:

Erlang version output

Install Elixir

# Add the Elixir plugin
asdf plugin-add elixir

# List all available Elixir versions
asdf list-all elixir

# Install a version that matches the OTP version (e.g., 1.9.4‑otp‑22)
asdf install elixir 1.9.4-otp-22

# Set it as the global version
asdf global elixir 1.9.4-otp-22

Check that both Erlang and Elixir are correctly installed:

elixir -v

Elixir version output

Start an interactive Elixir shell to confirm everything works:

iex

iex output

Conclusion

There are other ways to install Elixir, but keeping everything managed through asdf—including Ruby, Node, Python, Erlang, and Elixir—provides a consistent workflow.

Sources

Thanks to Adolfo Neto for feedback on Erlang OTP and pointing to Thinking Elixir.

Originally posted at guilherme44.com.

0 views
Back to Blog

Related posts

Read more »

I Think Ruby Isn’t Dynamic Enough…

Introduction This is, admittedly, more of a personal ramble than a technical article. For the past few years I have become something of a Crystal believer. Loo...

Unsigned Sizes: A Five Year Mistake

> A quick note for readers who don’t follow C3: it’s a systems language in the C tradition. Specifics below are C3’s, but the trade‑offs apply to any language t...

Organizing flash messages in Phoenix

!Guilherme Yamakawa de Oliveirahttps://media2.dev.to/dynamic/image/width=50,height=50,fit=cover,gravity=auto,format=auto/https%3A%2F%2Fdev-to-uploads.s3.amazona...