frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Boa: A standard-conforming embeddable JavaScript engine written in Rust

https://github.com/boa-dev/boa
61•maxloh•1w ago

Comments

sebastianconcpt•2h ago
What's the use case?
jasonjmcghee•2h ago
Likely similar to something like https://github.com/mlua-rs/mlua - but wanting to execute javascript (instead of lua, and no static libs?) in the context of native rust.

The alternative might be https://github.com/denoland/rusty_v8 but without needing C++ V8.

(this is the first I'm hearing of Boa)

written-beyond•1h ago
This mad man had the courage to present BOA a rust project at JS Conf. The project had it's spotlight taken by Bun and Deno. I also think the project was progressing pretty slowly from what people were expecting.
jasonjmcghee•28m ago
Seems pretty relevant- are JS Conf folks notoriously anti-rust or something?
afavour•17m ago
Bun and Deno are in totally different spaces to Boa IMO. Looks like Boa is comparable to QuickJS in the small embedded engine space.
nekevss•5m ago
Well the first two are runtimes built on top of JavaScriptCore and V8, respectively. So we're definitely in a different space.

QuickJS/QuickJS-NG might be a better comparison, but I think they are limited in specification conformance or at least selective in specification conformance in favor of remaining in a single file and fast. For instance, I'm not entirely sure whether they will be supporting Temporal once it goes Stage 4 because of the size of the feature, and I don't think they support Intl. But I also can't speak for QuickJS.

mort96•2h ago
There's typically a pretty big difference between an interpreter meant to be embeddable and one that's not. Trying to embed V8 and keep up with V8 API changes would be a huge amount of work. I could see myself using something like this instead of Lua for some projects where V8 would be too much.

My first thought was that this could be interesting for yt-dlp?

speps•2h ago
With projects like this competing against well known massive competitors (eg. the browser JS engines), not seeing their main competitors in a benchmark is a massive red flag to me: https://boajs.dev/benchmarks

Not seeing V8, SpiderMonkey JavaScriptCore is very strange...

mort96•2h ago
It's not competing with V8, SpiderMonkey and JavaScriptCore.
IshKebab•1h ago
Well, it is, because V8 is definitely an embeddable JS engine. For many people they might want to make a choice between V8 and Boa and for them the performance numbers are important information!
mort96•1h ago
People who need an extremely high performance JavaScript engine, where the extra performance is worth using an engine that's hard to embed, has an unstable API, and an absolutely massive unwieldy Google-style C++ code base with all the pain that entails, plus a JIT and all the limitations that entails, JITed V8 is the right choice.

People who just want to run JavaScript code where performance isn't such a big concern would prefer something like Boa (or the other engines listed on the comparison benchmark page).

Both have their uses, and their use case is almost entirely non-overlapping. You wouldn't choose Boa for a competitive web browser engine or as the runtime for your back-end server software. You would consider it for a plug-in system, or maybe a game's scripting system.

le-mark•1h ago
Is it though? V8 and spider monkey both have jits so performance numbers of the form “wow V8 is vastly faster than any of these other ones!” (similarly for sm). Does that really have any value?
baq•1h ago
It isn't, v8 will have anywhere between 2-1000x performance depending on the exact code it's jitting. Boa absolutely destroys v8 here though:

    use boa_engine::{Context, Source, JsResult};
    
    fn main() -> JsResult<()> {
      let js_code = r#"
          let two = 1 + 1;
          let definitely_not_four = two + "2";
    
          definitely_not_four
      "#;
    
      // Instantiate the execution context
      let mut context = Context::default();
    
      // Parse the source code
      let result = context.eval(Source::from_bytes(js_code))?;
    
      println!("{}", result.display());
    
      Ok(())
    }
echelon•21m ago
Oh my god, that's so easy to embed.

I have to check this out.

This is awesome. You literally just sold me on it.

0cf8612b2e1e•1h ago
This is offering a JS scripting layer in an otherwise Rust project. Performance is nice, but probably not a requirement.
gr4vityWall•1h ago
It's an embedded engine for scripting a bigger application. Its main "competitor" would be QuickJS.

Though they aren't really competing on anything as far as I can tell, so maybe calling it a "similar project" is more fitting.

vlovich123•1h ago
V8-jitless is in the benchmarks and even then still blows it away, as does quickjs.
jitl•31m ago
Both SpiderMonkey jitless (sm-jitless) and v8 jitless are on the benchmarks page, if you click the checkboxes you will see them in the graphs.
delduca•2h ago
Lua is the best for embedding.
ComputerGuru•1h ago
Nice to see another contender in this space. If OP is here, can you comment on runtime sandboxing and interop support? Can I selectively disable (or intercept) certain features like network support?
ModernMech•1h ago
Feels like a better name for an embeddable Python engine written in Rust.
k__•48m ago
Awesome!

I'm always on the lookout for embeddable JS engines.

How hard would it be to make Boa deterministic?

Like, with seeded randomness, etc.

jayflux•44m ago
Hi all, wow was not expecting this to be trending right now.

I’m the creator of Boa, you can catch my talk about it at JS Conf EU 2019 https://www.youtube.com/watch?v=_uD2pijcSi4

That said, today Boa has a whole team of maintainers who I’m sure will answer some questions here.

Yes the name does invoke the sense it’s a Python project but I liked it and stuck with it, I saw a Boa snake at a zoo once and knew I wanted to name my next project after it, I was also inspired by Mozilla at the time who named their projects after animals.

Speaking of Mozilla, Boa’s existence came to be because at the time I was working on Servo and wanted to include an all-rust JS engine, one didn’t really exist so I set about making one as a learning exercise, after around 2 years more joined me on that journey and today Boa is around 8 years old. It is not browser grade (although at 94.12% it is more compliant than some browser engines) but that doesn’t matter, plenty of Rust projects have found good use for it as they find it easy to embed and use, so we’re happy.

One recent example is Biome who use it for their plugin infrastructure. https://github.com/biomejs/biome/pull/7300

Another recent thing which we’re very proud is seeing our implementation of Temporal be used in V8 and other engines, so we’re also helping the wider ecosystem and raising all ships! (More here: https://boajs.dev/blog/2025/09/24/temporal-release)

We do hope to improve performance over the next year or so, hopefully that answers some of the Qs here.

vlovich123•38m ago
Do you see catching up on performance with v8-jitless as a goal or is conformance the primary goal right now? Any plans on doing a JIT? I was always impressed by the idea of Truffle where you implement the language semantics once and you get both interpreter and JIT safely out of it which is a huge source of vulnerabilities in traditional JIT systems
nekevss•18m ago
Hi, I'm another one of the maintainers on the project.

In general, we are shifting more to performance now than conformance. We currently sit at around 94% conformance, so there's not really that much more to go conformance-wise. The remaining conformance gains are a couple of the newer specification features and Intl related features. Our current conformance can be found at https://boajs.dev/conformance.

Regarding performance, we are already making some gains, with hopefully more to come. The best example of this was probably the updates to script-bench-rs with our most recent release (which can be found at this commit https://github.com/khvzak/script-bench-rs/commit/d9635de77d2...). We still obviously have more to improve on, but we have already made some pretty steady progress from where we were.

EDIT: I forgot to answer your question about v8-jitless. Obviously in the future it would be nice to be able to be more competitive with v8-jitless, but at least for me, I'd just like to focus on improving the Boa overall.

Ganipote•11m ago
Is it still boa's goals to be used with Servo? Servo is currently tightly coupled with spidermonkey, which makes this ain’t easy.
qbane•41m ago
I am not meant to be harsh, but note that it fails on a small number of test cases, on v0.21 that is ~900 out of ~50k. Strictly speaking it cannot be described as standard-comforming unless there is some reason behind every failed test. A better way to strive on standard conformance, like QuickJS takes, is to pin down the ecma262 revision and make it 100% compliant.

Transgenerational Epigenetic Inheritance: the story of learned avoidance

https://elifesciences.org/articles/109427
52•nabla9•1h ago•25 comments

Our investigation into the suspicious pressure on Archive.today

https://adguard-dns.io/en/blog/archive-today-adguard-dns-block-demand.html
862•immibis•9h ago•279 comments

Linux on the Fujitsu Lifebook U729

https://borretti.me/article/linux-on-the-fujitsu-lifebook-u729
121•ibobev•4h ago•85 comments

Boa: A standard-conforming embeddable JavaScript engine written in Rust

https://github.com/boa-dev/boa
62•maxloh•1w ago•27 comments

Archimedes – A Python toolkit for hardware engineering

https://pinetreelabs.github.io/archimedes/blog/2025/introduction.html
7•i_don_t_know•49m ago•1 comments

Weighting an average to minimize variance

https://www.johndcook.com/blog/2025/11/12/minimum-variance/
41•ibobev•4h ago•14 comments

Caffeinated Coffee Consumption or Abstinence to Reduce Atrial Fibrillation

https://jamanetwork.com/journals/jama/fullarticle/2841253
7•stared•35m ago•0 comments

Windhawk Windows classic theme mod for Windows 11

https://windhawk.net/mods/classic-theme-enable
118•znpy•3h ago•62 comments

The computer poetry of J. M. Coetzee's early programming career

https://sites.utexas.edu/ransomcentermagazine/2017/06/28/the-computer-poetry-of-j-m-coetzees-earl...
16•bluejay2•1h ago•3 comments

JVM exceptions are weird: a decompiler perspective

https://purplesyringa.moe/blog/jvm-exceptions-are-weird-a-decompiler-perspective/
9•birdculture•1w ago•0 comments

USA Gives South Korea Green Light to Build Nuclear Submarines

https://www.navalnews.com/naval-news/2025/10/usa-gives-south-korea-green-light-to-build-nuclear-s...
39•JumpCrisscross•1h ago•31 comments

TCP, the workhorse of the internet

https://cefboud.com/posts/tcp-deep-dive-internals/
242•signa11•13h ago•121 comments

Trellis AI (YC W24) Is Hiring: Streamline access to life-saving therapies

https://www.ycombinator.com/companies/trellis-ai/jobs/f4GWvH0-forward-deployed-engineer-full-time
1•macklinkachorn•3h ago

AWS Deprecates Two Dozen Services (Most of Which You've Never Heard Of)

https://www.lastweekinaws.com/blog/aws-deprecates-two-dozen-services-most-of-which-youve-never-he...
27•mooreds•1h ago•12 comments

FBI Director Waived Polygraph Security Screening for Three Senior Staff

https://www.propublica.org/article/fbi-kash-patel-dan-bongino-waived-polygraph
45•Jimmc414•2h ago•28 comments

The Nature of the Beast: Charles Le Brun's Human-Animal Hybrids (1806)

https://publicdomainreview.org/collection/le-brun-human-animal-hybrids/
35•Petiver•5d ago•5 comments

Messing with scraper bots

https://herman.bearblog.dev/messing-with-bots/
162•HermanMartinus•12h ago•57 comments

One Handed Keyboard

https://github.com/htx-studio/One-Handed-Keyboard
126•doppp•10h ago•78 comments

I implemented an ISO 42001-certified AI Governance program in 6 months

https://beabytes.com/iso42001-certified-ai-governance/
22•azhenley•3h ago•7 comments

Strap Rail

https://www.construction-physics.com/p/strap-rail
25•juliangamble•1w ago•1 comments

Lawmakers want to ban VPNs

https://www.eff.org/deeplinks/2025/11/lawmakers-want-ban-vpns-and-they-have-no-idea-what-theyre-d...
534•gslin•1d ago•297 comments

Streaming AI agent desktops with gaming protocols

https://blog.helix.ml/p/technical-deep-dive-on-streaming
61•quesobob•1w ago•24 comments

Designing a Language (2017)

https://cs.lmu.edu/~ray/notes/languagedesignnotes/
152•veqq•14h ago•96 comments

A new Google model is nearly perfect on automated handwriting recognition

https://generativehistory.substack.com/p/has-google-quietly-solved-two-of
454•scrlk•4d ago•255 comments

An Antivenom Cocktail, Made by a Llama

https://www.asimov.press/p/broad-antivenom
6•surprisetalk•1w ago•0 comments

Unofficial Microsoft Teams client for Linux

https://github.com/IsmaelMartinez/teams-for-linux
241•basemi•1w ago•215 comments

History and use of the Estes AstroCam 110

https://www.dembrudders.com/history-and-use-of-the-estes-astrocam-110.html
37•mmmlinux•1w ago•7 comments

Go's Sweet 16

https://go.dev/blog/16years
244•0xedb•21h ago•184 comments

The Mighty Simplex (2023)

https://galileo-unbound.blog/2023/05/03/the-mighty-simplex/
22•just_human•3h ago•4 comments

'No One Lives Forever' turns 25 and you still can't buy it legitimately

https://www.techdirt.com/2025/11/13/no-one-lives-forever-turns-25-you-still-cant-buy-it-legitimat...
337•speckx•1d ago•173 comments