sindresorhus/open

Open stuff like URLs, files, executables. Cross-platform.

View on GitHub ↗Jump to charts ↓Open shareable report

Summary Information

Updated 58 minutes ago
Type:Library / SDKCategory(s):Core & Utility LibrariesLanguages & Runtimes
Added to GitGenius on September 19th, 2026
Created on April 5th, 2014
Open Issues & Pull Requests: 1 (+0)
GitHub issues: Enabled
Number of forks: 258
Total Stargazers: 3,508 (+0)
Total Subscribers: 28 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 29.7 days
Mean response time: 418.2 days
90th percentile: 1393.0 days
Tracked items: 68

Most active contributors

Sign in to see contributor activity.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 0
New in 7 days: 1
Closed in 7 days: 1
Avg open age: N/A days
Stale 30+ days: 0
Stale 90+ days: 0

Recent activity

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

Top labels

  • enhancement (1)
  • help wanted (1)

Detailed Description

open is a Node.js package that opens URLs, files, and executables in their default applications across macOS, Windows, and Linux.

The package solves the problem of cross-platform application launching in command-line tools and scripts. It wraps the native open commands available on each operating system—`open` on macOS, `start` on Windows, and `xdg-open` on Linux—into a unified JavaScript API. The approach uses `spawn` instead of `exec` for safer process execution and includes the latest `xdg-open` script for Linux. It supports passing arguments to applications and can handle WSL paths to Windows applications.

The tool is designed for Node.js command-line tools and scripts, not for browser environments; Electron users should use `shell.openPath()` instead. It suits projects that need to programmatically launch applications without hardcoding platform-specific commands. The package is native ESM only and does not provide CommonJS exports, so projects using CommonJS must either convert to ESM or use dynamic imports. The tool does not make security guarantees, so users must sanitize untrusted input before passing it to the package.

The project maintains active development with regular updates. It provides platform-specific options including a `wait` parameter to block until the opened application exits, a `background` option on macOS to prevent bringing the app to the foreground, and a `newInstance` option on macOS to launch a new instance even if the app is already running. The package supports specifying which application to use for opening a target, with fallback to alternative apps if the primary choice fails, and includes an `apps` utility for auto-detecting correct application binaries across platforms.