Note
This README was generated with AI assistance to provide comprehensive documentation for the project.
A native macOS application that provides a dedicated wrapper for Open WebUI, built with SwiftUI and WebKit.
- Native macOS Integration: Built with SwiftUI for a seamless macOS experience
- WebKit Integration: Full-featured web browsing with navigation controls
- Smart URL Validation: Automatically validates Open WebUI instances by checking for
/static/splash.png - Persistent Settings: Remembers your Open WebUI URL across app launches
- Navigation Controls: Back, forward, and refresh functionality
- Screenshot Capability: Built-in screenshot functionality for web pages
- Keyboard Shortcuts: Quick access to common functions
- Window Management: Unified toolbar style with proper window controls
- macOS (compatible with SwiftUI and AppKit)
- Xcode (for building from source)
- Access to an Open WebUI instance
-
Clone this repository:
git clone <repository-url> cd OWUI
-
Open
OWUI.xcodeprojin Xcode -
Build and run the project (⌘R)
- When you first launch OWUI, you'll see a URL input field
- Enter your Open WebUI instance URL (e.g.,
http://localhost:8080) - Press Enter or click "Set URL" to connect
- The app will validate the URL by checking for the Open WebUI splash image
- Once validated, the web interface will load
- Setting URL: Enter your Open WebUI URL in the input field and press Enter or click "Set URL"
- URL Validation: The app automatically validates that the URL points to a valid Open WebUI instance
- Reset URL: Use the reset button in the toolbar or the keyboard shortcut to change your URL
- Back/Forward: Use the navigation buttons in the toolbar
- Refresh: Standard refresh or hard refresh (recreates the WebView)
- URL Display: Current URL is shown in the toolbar when connected
- Click the camera icon in the toolbar or use the keyboard shortcut
- Choose where to save your screenshot
- Screenshots capture the entire web content area
| Action | Shortcut |
|---|---|
| Reset URL | ⌘⇧R |
| Screenshot | ⌘⌥S |
| Refresh | ⌘R |
| Hard Refresh | ⌘⇧R |
The app includes custom menu items:
- OWUI URL Menu: Reset URL functionality
- Page Menu: Screenshot, refresh, and hard refresh options
- SwiftUI: Modern declarative UI framework
- WebKit:
WKWebViewfor web content rendering - SwiftData: Data persistence (currently minimal usage)
- AppKit: macOS-specific functionality and window management
ContentView: Main interface with URL input and WebViewWebView: NSViewRepresentable wrapper for WKWebViewOWUIApp: App entry point with menu commands and keyboard shortcutsItem: SwiftData model (currently unused but set up for future features)
The app validates Open WebUI instances by:
- Appending
/static/splash.pngto the provided URL - Making an HTTP request to check if the resource exists (200 status)
- Only accepting URLs that return a valid splash image
- Uses
UserDefaultsto persist the Open WebUI URL - State is managed through SwiftUI's
@Stateand@Bindingproperties NotificationCenterfor communication between app components
OWUI/
├── OWUI/
│ ├── ContentView.swift # Main UI implementation
│ ├── OWUIApp.swift # App entry point and commands
│ ├── Item.swift # SwiftData model
│ └── Assets.xcassets/ # App icons and images
├── OWUITests/ # Unit tests
├── OWUIUITests/ # UI tests
└── OWUI.xcodeproj/ # Xcode project
- Ensure you have Xcode installed
- Open
OWUI.xcodeproj - Select your target device/simulator
- Build with ⌘B or run with ⌘R
The project includes test targets:
OWUITests: Unit testsOWUIUITests: UI automation tests
Run tests with ⌘U in Xcode.
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
[Add your license information here]
For issues related to Open WebUI itself, visit the Open WebUI repository.
For issues specific to this macOS client, please open an issue in this repository.