The power of a type system, the expressiveness of functional programming, and the reliability of the highly concurrent, fault tolerant Erlang runtime, with a familiar and modern syntax.
import gleam/io
pub fn main() {
io.println("hello, friend!")
}Reliable and scalable
Running on the battle-tested Erlang virtual machine that powers planet-scale systems such as WhatsApp and Ericsson, Gleam is ready for workloads of any size.
Thanks to its multi-core actor based concurrency system that can run millions of concurrent green threads, fast immutable data structures, and a concurrent garbage collector that never stops the world, your service can scale and stay lightning fast with ease.
pub fn main() {
let subject = process.new_subject()
// Spawn a child green thread
process.spawn(fn() {
// Send a message back to the parent
process.send(subject, "Hello, Joe!")
})
// Wait for the message to arrive
echo process.receive(subject, 100)
}
Ready when you are
Gleam comes with compiler, build tool, formatter, editor integrations,
and package manager all built in, so creating a Gleam project is just
running gleam new
As part of the wider BEAM ecosystem, Gleam programs can use thousands of published packages, whether they are written in Gleam, Erlang, or Elixir.
β (main) gleam add gleam_json
Resolving versions
Downloading packages
Downloaded 2 packages in 0.01s
Added gleam_json v0.5.0
β (main) gleam test
Compiling thoas
Compiling gleam_json
Compiling app
Compiled in 1.67s
Running app_test.main
.
1 tests, 0 failuresHere to help
No null values, no exceptions, clear error messages, and a practical type system. Whether you're writing new code or maintaining old code, Gleam is designed to make your job as fun and stress-free as possible.
error: Unknown record field
ββ ./src/app.gleam:8:16
β
8 β user.alias
β ^^^^^^ Did you mean `name`?
The value being accessed has this type:
User
It has these fields:
.name
Multilingual
Gleam makes it easy to use code written in other BEAM languages such as Erlang and Elixir, so there's a rich ecosystem of thousands of open source libraries for Gleam users to make use of.
Gleam can additionally compile to JavaScript, enabling you to use your code in the browser, or anywhere else JavaScript can run. It also generates TypeScript definitions, so you can interact with your Gleam code confidently, even from the outside.
@external(erlang, "Elixir.HPAX", "new")
pub fn new(size: Int) -> Table
pub fn register_event_handler() {
let el = document.query_selector("a")
element.add_event_listener(el, fn() {
io.println("Clicked!")
})
}Friendly π
As a community, we want to be friendly too. People from around the world, of all backgrounds, genders, and experience levels are welcome and respected equally. See our community code of conduct for more.
Black lives matter. Trans rights are human rights. No nazi bullsh*t.
Lovely people
If you enjoy Gleam consider becoming a sponsor (or tell your boss to)
- π James Birtles
- π Dan Piths
- π Florian Kraft
- π Carlo Munguia
- π Kramer Hampton
- π Leon Qadirie
- π jooaf
- π Ben Martin
- π Guilherme de Maio
- π Hans Raaf
- π Benjamin Kane
- π Nigel Baillie
- π Erik Terpstra
- π Gabriela Sartori
- π Landon
- π Stefan
- π evanasse
- π Ben Myles
- π Natanael Oliveira
- π Hannes Nevalainen
- π Rupus Reinefjord
- π ErikML
- π Yasuo Higano
- π Vassiliy Kuzenkov
- π Ismael Abreu
- π Hubert MaΕkowski
- π Andy Young
- π Philpax
- π Billuc
- π Mark Rudolph
- π Michael Duffy
- π Ajit Krishna
- π Christopher Keele
- π Joey Kilpatrick
- π Eric Koslow
- π Eileen Noonan
- π Sakari Bergen
- π Guillaume Heu
- π Felix
- π Hari Mohan
- π Jake Wood
- π Mario Vellandi
- π Renato Massaro
- π Mark Dodwell
- π frankwang
- π Dylan Carlson
- π Coder
- π Henrik Tudborg
- π # <h1>NinaLovesToPutLongTextIntoNameFields.GitHubNamesArePrettyFun(IThinkThereAreOnlyAFewAnnoyingBugsAndOneFormShatStoppedWorkingCompletely).AnywayCheckOutGleam!ItIsAReallyCoolLanguageWithALovelyCommunity.BLM!CovidIsNotOver!TransRightsAreHumanRights!</h1>
- π Corentin J.
- π nunulk
- π Ernesto Malave
- π erlend-axelsson
- π Kirill Morozov
- π Antonio Farinetti
- π Ripta Pasay
- π Timo Sulg
- π Jan Skriver SΓΈrensen
- π Michael Jones
- π Sean Cribbs
- π simone
- π Valerio Viperino
- π Chris Lloyd
- π Rotabull
- π Nick Leslie
- π Volker Rabe
- π Jon Charter
- π Mikael Karlsson
- π Baqtiar
- π Lee Jarvis
- π Jerred Shepherd
- π Max McDonnell
- π Brian Glusman
- π Natalie Rose
- π Damir Vandic
- π Henning Dahlheim
- π Scott Zhu Reeves
- π Clifford Anderson
- π NicoVIII
- π G-J van Rooyen
- π Shane Poppleton
- π Kemp Brinson
- π Marius KalvΓΈ
- π Alexander Stensrud
- π Cris Holm
- π Julian Hirn
- π Thomas Crescenzi
- π Chew Choon Keat
- π Jachin Rupe
- π Brett Cannon
- π Ian M. Jones
- π Emma
- π Richard Viney
- π John Strunk
- π Christopher Dieringer
- π Thomas
- π Robert Attard
- π N. G. Scheurich
- π Carlos Saltos
- π Bruce Williams
- π Chris Vincent
- π JΓΈrgen Andersen
- π Dan Gieschen Knutson
- π MoeDev
- π Filip Figiel
- π Michael G
- π Γber Freitas Dias
- π Cole Lawrence
- π Aboio
- π Ian GonzΓ‘lez
- π Xucong Zhan
- π Joshua Steele
- π Michal Timko
- π Daniele
- π Erik Ohlsson
- π Alistair Smith
- π Rico Leuthold
- π Alexandre Del Vecchio
- π Dan Dresselhaus
- π upsidedowncake
- π Rintaro Okamura
- π David Cornu
- π Noah
- π Steinar Eliassen
- π Tristan de Cacqueray
- π Dan Strong
- π Manuel Rubio
- π Ethan Olpin
- π SR
- π Jonas Hedman EngstrΓΆm
- π Julian Schurhammer
- π Benjamin Moss
- π Francis Hamel
- π Matt Mullenweg
- π Martin Poelstra
- π Tim Brown
- π Wilson Silva
- π Russell Clarey
- π Nikolas
- π Jan Fooken
- π Tudor Luca
- π Stephane Rangaya
- π ollie
- π Mike Roach
- π Ameen Radwan
- π Graham
- π Martin Janiczek
- π Ruslan Ustitc
- π Tomasz Kowal
- π Scott Wey
- π n8n - Workflow Automation
- π Cameron Presley
- π shxdow
- π Antharuu
- π ι³γ¦‘
- π Mark Holmes
- π Leah Ulmschneider
- π Kevin Schweikert
- π Henry Warren
- π Chris Ohk
- π Sgregory42
- π Harry Bairstow
- π Comamoca
- π Evaldo Bratti
- π Race
- π METATEXX GmbH
- π jstcz
- π Matt Van Horn
- π Kuma Taro
- π Dave Lucia
- π Anthony Scotti
- π Danny Arnold
- π Adrian Mouat
- π Isaac Harris-Holt
- π Will Ramirez
- π Redmar Kerkhoff
- π Chad Selph
- π Optizio
- π Ryan Moore
- π Samu
- π Walton Hoops
- π Matt Savoia
- π Isaac McQueen
- π Sigma
- π Martin Rechsteiner
- π Jean-Adrien Ducastaing
- π Scott Trinh
- π Strandinator
- π Abel Jimenez
- π Shawn Drape
- π tommaisey
- π R.Kawamura
- π Aleksei Gurianov
- π Jimpjorpsβ’
- π Lexx
- π Adam Johnston
- π Hazel Bachrach
- π Jojor
- π SaΕ‘a JuriΔ
- π Krzysztof Gasienica-Bednarz
- π Danny Martini
- π Martin FojtΓk
- π Ivar Vong
- π KamilaP
- π Diemo Gebhardt
- π Niket Shah
- π Alex Houseago
- π Djordje Djukic
- π iskrisis
- π Sean Roberts
- π Nikolai Steen Kjosnes
- π Kero van Gelder
- π Jean-Luc Geering
- π Christopher De Vries
- π David Pendray
- π AndrΓ© Mazoni
- π Kile Deal
- π Pedro Correa
- π Thomas Coopman
- π Jimmy UtterstrΓΆm
- π Alembic
- π bgw
- π Bruno Konrad
- π Rohan
- π Fede Esteban
- π Fabrizio Damicelli
- π Dan
- π Arya Irani
- π Brad Mehder
- π Tristan Sloughter
- π Rodrigo Γlvarez
- π Yamen Sader
- π Barry Moore II
- π David Bernheisel
- π Patrick Wheeler
- π Christian Visintin
- π Jen Stehlik
- π Jon Lambert
- π Zsolt Kreisz
- π Edon Gashi
- π Mark Markaryan
- π lidashuang
- π Johan Strand
- π Grant Everett
- π Alex Manning
- π Robert Ellen
- π Iain H
- π Oliver Tosky
- π Sebastian Porto
- π Giacomo Cavalieri
- π Tobias Ammann
- π Kristoffer GrΓΆnlund
- π Renovator
- π Michael Mazurczak
- π Igor Montagner
- π Savva
- π albertchae
- π The Sentience Company
- π Qdentity
- π Ram Prasanth Udhaya Baskar
- π Leonardo Donelli
- π Sam Aaron
- π Caleb Falcione
- π Dylan Anthony
- π Falk Pauser
- π Andrew Varner
- π Pete Jodo
- π Nessa Jane Marin
- π Cyphernil
- π SΕawomir Ehlert
- π Arthur Weagel
- π Geir Arne Hjelle
- π Sam Zanca
- π Seve Salazar
- π Olaf Sebelin
- π Ed Rosewright
- π Rob Durst
- π Paul Guse
- π Markus WesslΓ©n
- π Curling IO
- π Brett Kolodny
- π Giovanni Kock Bonetti
- π Adi Iyengar
- π Alex Kelley
- π Nicklas Sindlev Andersen
- π Lennon Day-Reynolds
- π Sammy Isseyegh
- π Adam Brodzinski
- π Joseph Lozano
- π Luke Amdor
- π blurrcat
- π Oliver Medhurst
- π John BjΓΆrk
- π Jonas E. P
- π Nick Papadakis
- π Daniil Nevdah
- π Viv Verner
- π Reilly Tucker Siemens
- π Bjarte Aarmo Lund
- π Peter Rice
- π Matthew Jackson
- π RaΓΊl Chouza
- π Adam Daniels
- π ginkogruen
- π ZWubs
- π Robert Malko
- π Justin Lubin
- π OldhamMade
- π Aliaksiej Homza
- π James MacAulay
- π Lukas Bjarre
- π Rasmus
- π Evan Johnson
- π Jean Niklas L'orange
- π Isaac
- π Jan Pieper
- π rebecca
- π Joey Trapp
- π inoas
- π Jake Cleary
- π Johanna Larsson
- π Nomio
- π Constantin (Cleo) Winkler
- π Matt Heise
- π JΓ©rΓ΄me Schaeffer
- π dagi3d
- π bucsi
You're still here?
Well, that's all this page has to say. Maybe you should go read the language tour!
Let's go!Wanna keep in touch?
Subscribe to the Gleam newsletter
We send emails at most a few times a year, and we'll never share your email with anyone else.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.
