Latest stable OCaml: 5.5.2, released (5.5.2 release notes). 12 stable releases since 14 Mar 2024.
OCaml.
4.14.5newest stable publication
5.5.2newest 5.x
12 releasesstable since 2024
144 daysbetween the last two 4.14 patches
OCaml 4.14.5 shipped on 6 November 2026. The release notes name six security fixes and two ordinary bug fixes. The maintenance patch follows 4.14.4 by 144 calendar days. It fixes pattern compilation and compatibility with a new macOS version. OCaml 5.5.2 remains the newest 5.x release.
OCaml 5.5.2 came out on 23 October 2026 with fixes for six security advisories, OSEC-2026-21 to 26, and every one of them credits Anthropic as the reporter. They cover Str partial matching, an integer overflow in Unix.map_file, several problems in Marshal, command quoting on Windows and two flaws in the runtime_events consumer. The release also fixes two rare miscompilations, one with atomic loads and one with immediate range patterns. Other fixes cover macOS function detection and a runtime_events infinite loop.
The retained 24 October security-tracker snapshot contains 26 advisories, 10 of them against the compiler and runtime and the rest against packages such as tls, mirage-crypto, opam and cohttp. Marshal has come up three times: in 4.14.3 and 5.4.1 in February, in 5.5.1 in September and again now. 5.5.1 also fixed a type system bug for module-dependent functions.
As of 6 November 2026. OCaml security advisories.
Latest releases
4.14.5Six security fixes (OSEC-2026-18, 21–24 and 30) and two ordinary bug fixes.5.5.2Six security fixes (OSEC-2026-21 to 26) and two miscompilation fixes.5.5.1Type system fix for module-dependent functions; Marshal and bytecode loading overflows.5.5.0Feature release opening the 5.5 line.4.14.4Bigarray reshape overflow (CVE-2026-34353) and Windows filename quoting.5.4.1Marshal over-read fix for the 5.4 line.
Which OCaml line should I run?
Use OCaml 5.5.2 for a new project. OCaml 4.14.5 is the newest publication by date, but it patches the older runtime. Create a separate opam switch when testing a compiler upgrade.
Use Dune to rebuild the project in the new switch, then run its tests.
How quickly does a new line get its first patch?
A first patch took 77 to 189 days on the 3 patched 5.x lines with their launch in this data. There is no fixed patch deadline here.
What does 4.14 maintenance mean beside 5.x?
The 4.14 maintenance line has 4 releases in this window. Its latest patch arrived 144 days after 4.14.4. The 5.x branch spans 4 minor lines. These are observed publications; the chart does not promise future support.
Which security advisories reached my compiler?
OCaml 4.14.5 names 6 OSEC IDs: OSEC-2026-18, OSEC-2026-21, OSEC-2026-22, OSEC-2026-23, OSEC-2026-24, OSEC-2026-30. Five use the hyphenated OSEC prefix; the Windows command-quoting entry uses a space. OCaml 5.5.2 also names 6 IDs. Update the compiler line you actually run.
Advisory register: 24 October snapshot

Installing OCaml with opam
Install opam, OCaml's package manager, and let it build the compiler: opam init creates a default switch, an isolated environment holding one compiler and its packages. opam has supported Windows natively since 2.2.0; the current opam release is 2.6.1, from 7 October 2026.
- On Linux, macOS or *BSD, make sure gcc, build-essential, curl, unzip and bubblewrap are installed, then run the install script and initialise opam:
bash -c "sh <(curl -fsSL https://opam.ocaml.org/install.sh)" opam init eval $(opam env) - On Windows, install Git and opam with winget, then run
opam initin a new terminal:winget install Git.Git OCaml.opam - Add the OCaml Platform tools to the switch: Dune for builds, the language server for editors, odoc, ocamlformat and the utop REPL:
opam install dune ocaml-lsp-server odoc ocamlformat utop
If you said no to the shell hook during opam init, run eval $(opam env) in each new shell, or prefix commands with opam exec --. Distribution packages of opam can lag behind and may not know the newest compiler.

Which OCaml version to run, and moving to a new one
New projects should use the newest 5.x release. The 4.14 line still gets patch releases for code that can't move to OCaml 5's multicore runtime yet; the chart shows every compiler release since 2024 by series.
- Refresh the package list and create a switch for the new compiler. A switch named after a directory is picked automatically when you run opam inside it:
opam update opam switch create 5.5.2 eval $(opam env) - Reinstall your project's dependencies in the new switch, for example with
opam install . --deps-onlyfrom a directory with an opam file, then rebuild and run your tests. - Remove the old switch once nothing needs it:
opam switch remove <name>.
Creating a switch compiles OCaml from source, which takes a few minutes; the ocaml-system package reuses a compiler installed by your OS instead.
opam usage OCaml releases opam switch manual opam install manual

Pinning a package with opam
opam pin add <package> <target> holds a package at a version, or points it at a local path or a git branch or commit, and opam upgrade then leaves it alone or rebuilds it from that source.
- Pin to a version, a checkout, a git ref or the package's upstream repository:
opam pin add camlpdf 1.7 opam pin add camlpdf ~/src/camlpdf opam pin add opam-lib https://github.com/ocaml/opam.git#1.2 opam pin add opam-lib --dev-repo - To patch a dependency, fetch its source pinned, edit it, and rebuild from the checkout:
opam source <package> --dev-repo --pin cd <package> opam upgrade . - List pins with
opam pin listand drop one withopam pin remove <package>.

Questions people search for
What is the latest version of OCaml?
OCaml 5.5.2, released 23 October 2026 (5.5.2 release notes). Create a switch for it with opam switch create 5.5.2.
Is OCaml 4.14 still maintained?
Yes, it still gets patch releases: the newest is 4.14.5, from 6 November 2026. The 4.14 line exists for code that can't move to OCaml 5's runtime yet; new projects should start on 5.x.
How do I install OCaml on Windows?
Use opam, which runs natively on Windows since 2.2.0: winget install Git.Git OCaml.opam, then opam init in a new terminal. WSL 2 with the Linux instructions also works.

From @ocaml_org on X
[Changelog] Release of OCaml 5.5.2: We have the pleasure of celebrating the anniversary of the first powered flight in Europe by announcing the release of OCaml 5.5.2.
OCaml 5.5.2 fixes various minor security issues, two rare miscompilations, a… dlvr.it/TW2grr
The 5.5.2 announcement, posted the day after the release.
