---
title: "Ruby 4.0 released, with a roundup of what's new"
publication: "Ruby Weekly"
issue: 781
published_at: "2025-12-29"
canonical_url: "https://rubyweekly.com/issues/781"
---

And that's pretty much it. Happy New Year! |        

#​781 — December 29, 2025 

[Read on the Web](https://rubyweekly.com/issues/781)   

Ruby Weekly 

[![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/wp960ikco6qsorfjebym.jpg)](https://www.ruby-lang.org/en/news/2025/12/25/ruby-4-0-0-released/)  

[Ruby 4.0.0 Released](https://www.ruby-lang.org/en/news/2025/12/25/ruby-4-0-0-released/) — Yui Naruse of the core team took the helm for this year’s big, and extra special, Ruby release post where we celebrate 30 years of Ruby with the big v4.0! We’re listing a few of the most notable updates below, but it’s worth checking out the post, if only to enjoy the Ruby blog’s new theme. 

Yui Naruse   

[A New Design for the Official Ruby Site](https://www.ruby-lang.org/en/) — Unveiled a few days before v4.0, Ruby’s official web site has received more than a lick of paint, with a complete, modern redesign. It’s really well put together and gives off more of Ruby’s friendly vibe than the prior version. 

The Ruby Community   

**⚡️ RUBY 4.0 IN BRIEF:** 

- [ZJIT](https://docs.ruby-lang.org/en/master/jit/zjit_md.html) is a new prototype JIT compiler pitched as the 'next generation' of YJIT. It aims to offer extra performance in the _long term_ but isn't considered production ready yet, so it's behind a `--zjit` flag if you want to test it out.
- [Ruby Box](https://docs.ruby-lang.org/en/master/Ruby/Box.html) is an experimental isolation feature for separating definitions (monkey patches, globals, class definitions). It's akin to what you might call namespaces elsewhere (and stems largely from [a proposal to include namespaces into Ruby](https://bugs.ruby-lang.org/issues/21311)) but differs enough to warrant the term 'box'.
- ⚠️ `Net::HTTP` no longer auto-sets `Content-Type`. You must now explicitly set it for POST/PUT requests. This is quite a significant, yet subtle, breaking change with potentially negative outcomes, particularly when using API clients that aren't updated for Ruby 4.0.
- `Kernel#inspect`'s output can now be customized with which instance variables you want to display – potentially useful for hiding sensitive data like tokens.  

![](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/ofpdbo3ep9asw6axevqg.jpg)  

- Logical operators can now start lines _(see above)_ and will continue the expression from the previous line (akin to method chaining with`.`).
- Backtraces are cleaner, with internal frames hidden meaning C-implemented methods now show the Ruby source location.
- Ractors have seen some improvements, but remain experimental for now (though the aim is for the experimental status to be removed later in 2026).
- [Set](https://docs.ruby-lang.org/en/master/Set.html) is now a _core_ class and no longer needs to be autoloaded on use.
- `Array#rfind` is a new, more efficient alternative to `arr.reverse_each.find`.
- A myriad of performance boosts, like a faster `Class#new` and faster GC.
- Ruby 4.0 is now available in [the official Ruby Docker images](https://hub.docker.com/_/ruby) and is how I tested out some of the things above, as I usually wait for the `x.0.1` release for my day-to-day work machine... ;-)    

🎄 OK, this really _is_ the final issue of 2025. Our next _scheduled_ issue is on Thursday, January 8 where we'll have even more Ruby 4.0 goodies.         

Curated by [Peter Cooper](https://twitter.com/cooperx86) and [Glenn Goodrich](https://twitter.com/ruprict).
Published by [Cooperpress](https://cooperpress.com/). 

[Change your email](https://rubyweekly.com/edit_subscription/*|UID|*) or [Stop getting this newsletter.](https://rubyweekly.com/leave/*|UID|*) 

© Cooper Press Ltd · Fairfield Enterprise Centre, Louth, LN11 0LS, United Kingdom 

Other weekly newsletters we publish include [Postgres Weekly](https://postgresweekly.com/), [React Status](https://react.statuscode.com/), [Frontend Focus](https://frontendfoc.us/), and [JavaScript Weekly](https://javascriptweekly.com/).
