robertkrimen/otto

A JavaScript interpreter in Go (golang)

View on GitHub ↗Jump to charts ↓

robertkrimen/otto has 8k+ stars and 600+ forks on GitHub, is written in Go, and was last pushed on Oct 8, 2026. Data as of . Signed-in members get hourly updates — create a free account.

Summary Information

Updated 18 minutes ago
Added to GitGenius on October 1st, 2026
Created on October 6th, 2012
Open Issues & Pull Requests: 66 (+6)
GitHub issues: Enabled
Number of forks: 603
Total Stargazers: 8,452 (+0)
Total Subscribers: 177 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 2.2 hours
Mean response time: 2.6 hours
90th percentile: 5.5 hours
Tracked items: 7

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 4
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 659 days
Stale 30+ days: 4
Stale 90+ days: 4

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

  • help wanted (1)

Most active issues this week

Sign in to see which issues are moving.
Sign in

Detailed Description

Otto is a JavaScript interpreter written in Go that executes JavaScript code natively within Go applications.

The tool solves the problem of running JavaScript code from within Go programs without requiring an external JavaScript runtime. It works by parsing JavaScript source code into an abstract syntax tree and then interpreting that tree directly. The interpreter supports core JavaScript functionality including variable assignment, function calls, object manipulation, and error handling. Developers can execute arbitrary JavaScript, retrieve values from the virtual machine, set Go functions that JavaScript can call, and interrupt long-running executions through an interrupt channel.

Otto targets ES5 and is suitable for embedding JavaScript execution in Go applications that need scripting capabilities or dynamic code evaluation. It works well for scenarios where lightweight JavaScript evaluation is needed without the overhead of spawning a separate Node.js or browser process. The tool includes an optional underscore.js utility library and provides a command-line interface for running JavaScript files or interactive code. However, potential adopters should be aware that the project does not support strict mode enforcement, has limited ES6 support, and lacks timing functions like setTimeout and setInterval which are not part of the ECMAScript specification. Regular expression support is constrained by Go's re2 engine, which does not support backtracking and has different whitespace character definitions than JavaScript, making some ECMA5-compliant patterns incompatible.

The project shows minimal recent development activity with infrequent commits and limited responsiveness to pull requests. The codebase remains stable but receives sparse maintenance, suggesting it is in a mature but largely dormant state. Documentation is sparse beyond the basic README examples, and the project does not actively incorporate community contributions.