HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
brython-dev
brython
Python2015–2026
brython-dev / brython

brython

Brython (Browser Python) is an implementation of Python 3 running in the browser

14Distinct people
17Mentions
0Explicit recommenders
6.6KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Brython (Browser Python) is an implementation of Python 3 running in the browser

GitHub

Where it is used

No documented product use was verified in the last source check.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 1:49:46 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year17 dated mentions

Observed mentions: 2015-01-20 09:21:32 UTC to 2026-01-06 22:45:56 UTC.

0123452015-01-01 00:00:00 UTC to 2016-01-01 00:00:00 UTC (exclusive): 3 mentions; 2 submissions, 1 comments20152016-01-01 00:00:00 UTC to 2017-01-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments2017-01-01 00:00:00 UTC to 2018-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 5 mentions; 0 submissions, 5 comments20202021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 3 mentions; 2 submissions, 1 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-01-01 00:00:00 UTC to 2027-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments. Incomplete calendar period.2026*

* An incomplete calendar period is marked with an outlined bar. Its count is not directly comparable with a full period.

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20152015-01-01 00:00:00 UTC2016-01-01 00:00:00 UTC321
20162016-01-01 00:00:00 UTC2017-01-01 00:00:00 UTC110
20172017-01-01 00:00:00 UTC2018-01-01 00:00:00 UTC000
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC000
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC000
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC505
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC312
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC321
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC000
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC101
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC000
2026 (partial)2026-01-01 00:00:00 UTC2027-01-01 00:00:00 UTC101

What Hacker News says

17 sources
There are multiple Python 3 interpreters written in JavaScript that were very likely included in the training data. For example [1] [2] [3] I once gave Claude (Opus 3.5) a problem that I thought was for sure too difficult for an LLM, and much to my surprise it spat out a very convincing solution. The surprising part was I was already familiar with the solution - because it was almost a direct copy/paste (uncredited) from a blog post that I read only a few hours earlier. If I hadn't read that blog post, I would have been none the wiser that copy/pasting Claude's output would be potential IP theft. I would have to imagine that LLMs solve a lot of in-training-set problems this way and people never realize they are dealing with a copyright/licensing minefield. A more interesting and convincing task would be to write a Python 3 interpeter in
Read the rest
JavaScript that uses register based bytecode instead of stack based, supports optimizing the bytecode by inlining procedures and constant folding, and never allocates memory (all work is done in a single user provided preallocated buffer). This would require integrating multiple disparate coding concepts and not regurgitating prior art from the training data [1] https://github.com/skulpt/skulpt [2] https://github.com/brython-dev/brython [3] https://github.com/yzyzsun/PyJS
In Opus 4.5 is not the normal AI agent experience that I have had thus far
This uses Pyodide [0] under the hood [1], which is CPython compiled to WebAssembly. In all my tests of it, loading takes a long time ~5 seconds. Coldbrew [2], another distribution of CPython on Wasm, is another option with similar load times. And Brython [3] is a completely different option without long load time: a Python interpreter implemented in JavaScript. If load time is important, Brython is pretty nice. If feature completeness is important, Pyodide and Coldbrew are probably best. [0] https://github.com/pyscript/pyscript/blob/main/pyscriptjs/sr... [1] https://github.com/pyodide/pyodide [2] https://github.com/plasticityai/coldbrew [3] https://github.com/brython-dev/brython
In PyScript: Run Python in your HTML
I discovered this about a month ago, and it deserves to go up to the sky. The GitHub page is linked at the end. Some articles/content that relates to this ([4] is pretty cool and definitely check it out, so is [6]): [1] https://brython.info/static_doc/en/intro.html [2] https://towardsdatascience.com/run-python-code-on-websites-e... [3] https://stackabuse.com/an-introductory-guide-to-brython [4] https://rayluo.github.io/brython-project-template/ [5] https://github.com/rayluo/brip [6] https://github.com/brython-dev/brython/wiki/Brython%20in%20t... [7] https://academy.cs.cmu.edu/ (CMU's academy website runs on Brython) Here's the GitHub page: https://github.com/brython-dev/brython/ And the Wiki, for examples -https://github.com/brython-dev/brython/wiki/Brython%20in%20t... If you're familiar with all that's going on with the source code or at
Read the rest
least some parts of it, and have time to spare, do take the time out to contribute to this project. It's pretty insane what they're building. You can join their Google Groups forum here: https://groups.google.com/forum/?fromgroups=#!forum/brython
In Brython: an implementation of Python 3 running in the browser
I've looked into Brython and other "Python in the browser" implementations (transcrypt.org, pypyjs.org). It's fun! At a high level, the approaches are: * Create a Python interpreter that is able to run Python code directly in the browser (PyPy.js, Brython) * Transpile Python code into JavaScript and send that to the browser (Transcrypt, which also does a lot of tree shaking to keep the transpiled code efficient). Here are the benefits, IMHO: * Share helper code and class definitions across environments * Most of the std lib, and a handful of popular 3rd party libs, are supported * In the rare happy path, only have to think about one programming language. The downsides are: * Slow. For the "send an interpreter" approach (Brython, PyPy.js), the browser has to compile a whole compiler before moving on to running your code. * Incompatibilit
Read the rest
ies. For Brython and Transcrypt, C parts of the standard lib have to be re-written in Python for compatibility. So when you're importing something from the itertools package, it's actually a custom implementation like this: https://github.com/brython-dev/brython/blob/master/www/src/L.... The custom code will not always be exactly compatible with the CPython implementation. * Incompleteness. Some std libs aren't implemented, or are only partially implemented. 3rd party libs that rely on these will not work. Popular 3rd party libs like sklearn which get their power by wrapping C/Fortran libraries need custom wrappers that don't exist (AFAIK) yet. * You still gotta JavaScript. Even in the best transpilation scenarios, things break and you have to figure out what the generated or interpreted code is doing. This is especially tough for Python in the browser tools, which aren't widely used, so have both undiscovered bugs and a lack of community support. In my experience, working in a transpiled codebase doesn't mean you have to learn one thing, but three: the source language, the target language, and the frankenstein monster of the logic/compromises bridging the two. * Tooling. The ecosystem hasn't reached a critical mass to support tooling. It's unclear if there's enough excitement in the Python community to get it there. With all that said, unless you're a true believer or just want to have a little fun (again, it is fun!), I wouldn't recommend this.
In Brython – A Python 3 implementation for client-side web programming
just a correction for my comment above, I should have written "Brython feels like a Python interpreter", but it's transpiling to JS too, the difference is that it's done directly in the browser (it's also possible ahead of time from CLI), and then the JS is stored in indexecDB (this can probably be compared to .pyc from CPython). It's explained there for the curious: https://github.com/brython-dev/brython/wiki/How%20Brython%20... edit: I've updated initial comment.
In Brython – A Python 3 implementation for client-side web programming
Brython feels like a Python interpreter (it's actually transpiling to javascript with a thin compatibility layer, cf. https://github.com/brython-dev/brython/wiki/How%20Brython%20...), you can use Python live in the browser, while Transcrypt transpile Python (or nearly Python, depending on what features you activate) to Javascript ahead of time (this can be achieved with Brython CLI too). Brython has a better compatibility, but Transcrypt being pure javascript on the browser should be faster (I didn't made the comparison myself though). Both projects are complementary. PyJS is a hostile fork (or I should say "hijack", but that's a long story) of Pyjamas, a Python 2 to Javascript compiler. I'm not sure where they are now, but at the time Pyjamas was Python 2 only and there was no plan to move it to Python 3 as this would mean a full rewrite
Read the rest
of the transpiler. It's pretty similar to Transcrypt except that it comes with a library which is a rewrite of GWT for Python. With that you end up writing web application in a similar way as you would do for desktop application. I've been using Pyjamas for years, it was working quite well (but you had to get used to some bugs/incompatibilities with Python, and I have not experienced that with Brython so far). About the library, while it seemed like a neat idea at the beginning, at the end it was an experience too distant from web developing, and meanwhile HTML and CSS improved a lot so it doesn't really makes sense anymore. So from my experience : - you want real Python 3 and being able to use it dynamically (in a live console for instance) ==> Brython - you want something as fast as javascript with clean syntax of Python ==> Transcrypt Both work well with JS libraries, Brython in addition re-implement most of Python standard API (but it's long to import, so it's often better to use JS libraries or native methods). In addition, and really subjectively, I find the Brython community really nice, the main developer is reactive and kind. Brython gives you real Python traceback, and you can even run pdb inside the browser (which will block your scripts) or an Inspector (a non blocking Python console) allowing to transfer objects between Python and Javascript for inspection in dev tools. edit: corrected the initial statement, Brython feels like an interpreter, but it's actually transpiling, so you don't have such a big performance impact. edit2: added that Brython can be compiled AOT from CLI too + precisions that I didn't compared with Transcrypt myself
In Brython – A Python 3 implementation for client-side web programming

Showing the 15 most recent of 17 sources. Enable JavaScript to search and browse every indexed mention.

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.