explaingit

adm1nsys/safari-ai-extension

Analysis updated 2026-05-18

8JavaScriptAudience · developerComplexity · 2/5LicenseSetup · hard

TLDR

A working reference example of a Safari extension generated by Apple Intelligence on OS 27, showing how to find, extract, and manually edit AI-created browser extensions.

Mindmap

mindmap
  root((Safari-Ai-Extension))
    What it does
      Generate extension from text prompt
      Store in MagicExtensions folder
      Edit source files directly
      Extract via feedback form
    Tech Stack
      JavaScript
      Safari Web Extension API
      macOS 27 beta
    Use Cases
      Reference for AI extension development
      YouTube page customization
      Cross-device extension deployment
    Audience
      Developers on Apple platforms
      iOS and macOS beta testers
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Use as a starting point to understand how Apple Intelligence-generated Safari extensions are structured and where they are stored.

USE CASE 2

Customize YouTube pages on Safari across Mac, iPhone, and iPad by editing the extension files directly.

USE CASE 3

Learn how to extract the source code of any AI-generated Safari extension using the feedback form trick.

What is it built with?

JavaScriptSafari Web Extension APImacOS 27iOS 27

How does it compare?

adm1nsys/safari-ai-extensionabivan-tech/zvec-mcploafdaddy/discoverr-bot
Stars897
LanguageJavaScriptJavaScriptJavaScript
Setup difficultyhardmoderatemoderate
Complexity2/53/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · hard Time to first run · 1h+

Requires macOS 27, iOS 27, or iPadOS 27 developer beta, not available on any released OS version.

MIT license: use freely for any purpose, including commercial projects, as long as you keep the copyright notice.

In plain English

Safari on macOS 27, iOS 27, and iPadOS 27 can generate a complete browser extension from a plain text description. You describe what you want, the on-device model writes the necessary files, and Safari installs it immediately. This repo is a working example of one such extension, created with that "Describe an Extension" feature and then edited by hand. The extension itself is a small YouTube customization: it lets you change the country code next to the YouTube logo, recolor the logo, add a frosted-glass header effect, and show like and dislike counts. Those features are not the point. The point is to show developers exactly what an AI-generated extension looks like, where it is stored on the device, and how to find, extract, and modify the source files. Finding the source requires a bit of digging. Apple presents the feature as a no-files, no-code experience, so the generated code is not in an obvious location. The repo documents that these extensions land in a specific Safari container folder called MagicExtensions. Each extension there has a standard set of web extension files plus the original text prompt that created it. Editing files in that folder directly updates the extension in Safari. The repo also explains a second method for extracting source code: using Safari's own feedback form. Submitting feedback on a generated extension causes Safari to bundle a complete snapshot of all the files into a temporary folder, which you can copy before closing the form. For iteration, you can go back to the AI assistant in Safari and refine the extension in plain language, or edit the files directly for more precise control. The repo recommends generating a first draft with AI and then hand-tuning the code, which is the approach used to build this example. The extension runs on all three Apple platforms since it uses the standard Web Extension format. Cross-device installation by copying the folder is documented but marked experimental, as Safari's internal registration behavior is not fully confirmed. The repo targets developer beta software and notes that file paths may change before public release.

Copy-paste prompts

Prompt 1
Show me how the MagicExtensions folder in Safari works on macOS 27 and how to edit an AI-generated extension's content.js file directly.
Prompt 2
I generated a Safari extension with Apple Intelligence but want to add a new feature manually. Walk me through editing the files in the MagicExtensions container folder.
Prompt 3
How do I use the Safari feedback form trick to extract the full source code of an AI-generated extension, including the original prompt?
Prompt 4
Help me write a manifest.json for a Safari Web Extension that runs on YouTube pages across macOS, iOS, and iPadOS 27.

Frequently asked questions

What is safari-ai-extension?

A working reference example of a Safari extension generated by Apple Intelligence on OS 27, showing how to find, extract, and manually edit AI-created browser extensions.

What language is safari-ai-extension written in?

Mainly JavaScript. The stack also includes JavaScript, Safari Web Extension API, macOS 27.

What license does safari-ai-extension use?

MIT license: use freely for any purpose, including commercial projects, as long as you keep the copyright notice.

How hard is safari-ai-extension to set up?

Setup difficulty is rated hard, with roughly 1h+ to a first successful run.

Who is safari-ai-extension for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Scan in gitsafehub Deploy in gitdeployhub adm1nsys on gitmyhub

Verify against the repo before relying on details.