{"id":14978514,"url":"https://github.com/electron/universal","last_synced_at":"2026-04-22T03:00:34.977Z","repository":{"id":38173890,"uuid":"305878940","full_name":"electron/universal","owner":"electron","description":"Create Universal macOS applications from two x64 and arm64 Electron applications","archived":false,"fork":false,"pushed_at":"2026-04-14T22:50:50.000Z","size":1542,"stargazers_count":147,"open_issues_count":24,"forks_count":46,"subscribers_count":7,"default_branch":"main","last_synced_at":"2026-04-19T04:03:21.803Z","etag":null,"topics":["electron","macos","universal"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/electron.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-10-21T01:46:35.000Z","updated_at":"2026-04-14T11:17:10.000Z","dependencies_parsed_at":"2026-04-01T01:02:20.630Z","dependency_job_id":null,"html_url":"https://github.com/electron/universal","commit_stats":{"total_commits":95,"total_committers":21,"mean_commits":4.523809523809524,"dds":0.7473684210526316,"last_synced_commit":"bf62ed4113dac1ddc9190d5d300f867b3944c651"},"previous_names":[],"tags_count":30,"template":false,"template_full_name":null,"purl":"pkg:github/electron/universal","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/electron%2Funiversal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/electron%2Funiversal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/electron%2Funiversal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/electron%2Funiversal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/electron","download_url":"https://codeload.github.com/electron/universal/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/electron%2Funiversal/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32119065,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-22T00:31:26.853Z","status":"online","status_checked_at":"2026-04-22T02:00:05.693Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["electron","macos","universal"],"created_at":"2024-09-24T13:57:49.704Z","updated_at":"2026-04-22T03:00:34.968Z","avatar_url":"https://github.com/electron.png","language":"TypeScript","readme":"# @electron/universal\n\n\u003e Create universal macOS Electron applications\n\n[![Test](https://github.com/electron/universal/actions/workflows/test.yml/badge.svg)](https://github.com/electron/universal/actions/workflows/test.yml)\n[![NPM package](https://img.shields.io/npm/v/@electron/universal)](https://npm.im/@electron/universal)\n[![API docs](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fregistry.npmjs.org%2F%40electron%2Funiversal%2Flatest\u0026query=%24.version\u0026logo=typescript\u0026logoColor=white\u0026label=API%20Docs)](https://packages.electronjs.org/universal)\n\n## Usage\n\nThis package takes an x64 app and an arm64 app and glues them together into a\n[Universal macOS binary](https://developer.apple.com/documentation/apple-silicon/building-a-universal-macos-binary).\n\nNote that parameters need to be **absolute** paths.\n\n```typescript\nimport { makeUniversalApp } from '@electron/universal';\n\nawait makeUniversalApp({\n  x64AppPath: 'path/to/App_x64.app',\n  arm64AppPath: 'path/to/App_arm64.app',\n  outAppPath: 'path/to/App_universal.app',\n});\n```\n\nFor full API usage, see the [API documentation](https://packages.electronjs.org/universal).\n\n## Advanced configuration\n\nThe basic usage patterns will work for most apps out of the box. Additional configuration\noptions are available for advanced usecases.\n\n### Merging ASAR archives to reduce app size\n\n**Added in [v1.2.0](https://github.com/electron/universal/commit/38ab1c3559e25382957d608e49e624dc72a4409c)**\n\nIf you are using ASAR archives to store your Electron app's JavaScript code, you can use the\n`mergeASARs` option to merge your x64 and arm64 ASAR files to reduce the bundle size of\nthe output Universal app.\n\nIf some files are present in only the x64 app but not the arm64 version (or vice-versa),\nyou can exclude them from the merging process by specifying a `minimatch` pattern\nin `singleArchFiles`.\n\n```typescript\nimport { makeUniversalApp } from '@electron/universal';\n\nawait makeUniversalApp({\n  x64AppPath: 'path/to/App_x64.app',\n  arm64AppPath: 'path/to/App_arm64.app',\n  outAppPath: 'path/to/App_universal.app',\n  mergeASARs: true,\n  singleArchFiles: 'node_modules/some-native-module/lib/binding/Release/**', // if you have files in your asar that are unique to x64 or arm64 apps\n});\n```\n\nIf `@electron/universal` detects an architecture-unique file that isn't covered by the\n`singleArchFiles` rule, an error will be thrown.\n\n### Skip lipo for certain binaries in your Universal app\n\n**Added in [1.3.0](https://github.com/electron/universal/commit/01dfb8a9636965fe154192b07934670dd42509f3)**\n\nIf your Electron app contains binary resources that are already merged with the\n`lipo` tool, providing a [`minimatch`] pattern to matching files in the `x64ArchFiles`\nparameter will prevent `@electron/universal` from attempting to merge them a second time.\n\n```typescript\nimport { makeUniversalApp } from '@electron/universal';\n\nawait makeUniversalApp({\n  x64AppPath: 'path/to/App_x64.app',\n  arm64AppPath: 'path/to/App_arm64.app',\n  outAppPath: 'path/to/App_universal.app',\n  mergeASARs: true,\n  x64ArchFiles: '*/electron-helper', // `electron-helper` is a binary merged using `lipo`\n});\n```\n\nIf `@electron/universal` detects a lipo'd file that isn't covered by the `x64ArchFiles` rule,\nan error will be thrown.\n\n### Including already codesigned app bundles into your Universal app\n\n**Added in [v1.4.0](https://github.com/electron/universal/commit/b02ce7697fd2a3c2c79e1f6ab6bf7052125865cc)**\n\nBy default, the merging process will generate an `ElectronAsarIntegrity` key for\nany `Info.plist` files in your Electron app.\n\nIf your Electron app bundles another `.app` that is already signed, you need to use\nthe `infoPlistsToIgnore` option to avoid modifying that app's plist.\n\n```typescript\nimport { makeUniversalApp } from '@electron/universal';\n\nawait makeUniversalApp({\n  x64AppPath: 'path/to/App_x64.app',\n  arm64AppPath: 'path/to/App_arm64.app',\n  outAppPath: 'path/to/App_universal.app',\n  infoPlistsToIgnore: 'my-internal.app/Contents/Info.plist'\n});\n```\n\n## FAQ\n\n#### The app is twice as big now, why?\n\nA Universal app is just the x64 app and the arm64 app glued together into a single application.\nIt's twice as big because it contains two apps in one.\n\nMerging your ASAR bundles can yield significant app size reductions depending on how large\nyour `app.asar` file is.\n\n#### What about native modules?\n\nOut of the box, you don't need to worry about building universal versions of your\nnative modules. As long as your x64 and arm64 apps work in isolation, the Universal\napp will work as well.\n\nNote that if you are using `mergeASARs`, you may need to add architecture-specific\nbinary resources to the `singleArchFiles` pattern.\nSee [Merging ASARs usage](#merging-asar-archives-to-reduce-app-size) for an example.\n\n[`minimatch`]: https://github.com/isaacs/minimatch?tab=readme-ov-file#features\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felectron%2Funiversal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felectron%2Funiversal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felectron%2Funiversal/lists"}