├── .gitignore
├── .idea
└── .gitignore
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── LICENSE
├── README.md
├── assets
├── ico.icns
├── ico.ico
└── ico.png
├── config_example.json
├── index.html
├── main.js
├── modal-preload.js
├── modal.html
├── modal.js
├── package-lock.json
├── package.json
├── preload.js
├── renderer.js
└── styles
├── index.css
└── modal.css
/.gitignore:
--------------------------------------------------------------------------------
1 | .idea/
2 | node_modules
3 | /dist/
4 | /config.json
5 |
--------------------------------------------------------------------------------
/.idea/.gitignore:
--------------------------------------------------------------------------------
1 | # Default ignored files
2 | /shelf/
3 | /workspace.xml
4 | # Editor-based HTTP Client requests
5 | /httpRequests/
6 | # Datasource local storage ignored files
7 | /dataSources/
8 | /dataSources.local.xml
9 |
--------------------------------------------------------------------------------
/CODE_OF_CONDUCT.md:
--------------------------------------------------------------------------------
1 | # Contributor Covenant Code of Conduct
2 |
3 | ## Our Pledge
4 |
5 | We as members, contributors, and leaders pledge to make participation in our
6 | community a harassment-free experience for everyone, regardless of age, body
7 | size, visible or invisible disability, ethnicity, sex characteristics, gender
8 | identity and expression, level of experience, education, socio-economic status,
9 | nationality, personal appearance, race, religion, or sexual identity
10 | and orientation.
11 |
12 | We pledge to act and interact in ways that contribute to an open, welcoming,
13 | diverse, inclusive, and healthy community.
14 |
15 | ## Our Standards
16 |
17 | Examples of behavior that contributes to a positive environment for our
18 | community include:
19 |
20 | * Demonstrating empathy and kindness toward other people
21 | * Being respectful of differing opinions, viewpoints, and experiences
22 | * Giving and gracefully accepting constructive feedback
23 | * Accepting responsibility and apologizing to those affected by our mistakes,
24 | and learning from the experience
25 | * Focusing on what is best not just for us as individuals, but for the
26 | overall community
27 |
28 | Examples of unacceptable behavior include:
29 |
30 | * The use of sexualized language or imagery, and sexual attention or
31 | advances of any kind
32 | * Trolling, insulting or derogatory comments, and personal or political attacks
33 | * Public or private harassment
34 | * Publishing others' private information, such as a physical or email
35 | address, without their explicit permission
36 | * Other conduct which could reasonably be considered inappropriate in a
37 | professional setting
38 |
39 | ## Enforcement Responsibilities
40 |
41 | Community leaders are responsible for clarifying and enforcing our standards of
42 | acceptable behavior and will take appropriate and fair corrective action in
43 | response to any behavior that they deem inappropriate, threatening, offensive,
44 | or harmful.
45 |
46 | Community leaders have the right and responsibility to remove, edit, or reject
47 | comments, commits, code, wiki edits, issues, and other contributions that are
48 | not aligned to this Code of Conduct, and will communicate reasons for moderation
49 | decisions when appropriate.
50 |
51 | ## Scope
52 |
53 | This Code of Conduct applies within all community spaces, and also applies when
54 | an individual is officially representing the community in public spaces.
55 | Examples of representing our community include using an official e-mail address,
56 | posting via an official social media account, or acting as an appointed
57 | representative at an online or offline event.
58 |
59 | ## Enforcement
60 |
61 | Instances of abusive, harassing, or otherwise unacceptable behavior may be
62 | reported to the community leaders responsible for enforcement at
63 | .
64 | All complaints will be reviewed and investigated promptly and fairly.
65 |
66 | All community leaders are obligated to respect the privacy and security of the
67 | reporter of any incident.
68 |
69 | ## Enforcement Guidelines
70 |
71 | Community leaders will follow these Community Impact Guidelines in determining
72 | the consequences for any action they deem in violation of this Code of Conduct:
73 |
74 | ### 1. Correction
75 |
76 | **Community Impact**: Use of inappropriate language or other behavior deemed
77 | unprofessional or unwelcome in the community.
78 |
79 | **Consequence**: A private, written warning from community leaders, providing
80 | clarity around the nature of the violation and an explanation of why the
81 | behavior was inappropriate. A public apology may be requested.
82 |
83 | ### 2. Warning
84 |
85 | **Community Impact**: A violation through a single incident or series
86 | of actions.
87 |
88 | **Consequence**: A warning with consequences for continued behavior. No
89 | interaction with the people involved, including unsolicited interaction with
90 | those enforcing the Code of Conduct, for a specified period of time. This
91 | includes avoiding interactions in community spaces as well as external channels
92 | like social media. Violating these terms may lead to a temporary or
93 | permanent ban.
94 |
95 | ### 3. Temporary Ban
96 |
97 | **Community Impact**: A serious violation of community standards, including
98 | sustained inappropriate behavior.
99 |
100 | **Consequence**: A temporary ban from any sort of interaction or public
101 | communication with the community for a specified period of time. No public or
102 | private interaction with the people involved, including unsolicited interaction
103 | with those enforcing the Code of Conduct, is allowed during this period.
104 | Violating these terms may lead to a permanent ban.
105 |
106 | ### 4. Permanent Ban
107 |
108 | **Community Impact**: Demonstrating a pattern of violation of community
109 | standards, including sustained inappropriate behavior, harassment of an
110 | individual, or aggression toward or disparagement of classes of individuals.
111 |
112 | **Consequence**: A permanent ban from any sort of public interaction within
113 | the community.
114 |
115 | ## Attribution
116 |
117 | This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118 | version 2.0, available at
119 | https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120 |
121 | Community Impact Guidelines were inspired by [Mozilla's code of conduct
122 | enforcement ladder](https://github.com/mozilla/diversity).
123 |
124 | [homepage]: https://www.contributor-covenant.org
125 |
126 | For answers to common questions about this code of conduct, see the FAQ at
127 | https://www.contributor-covenant.org/faq. Translations are available at
128 | https://www.contributor-covenant.org/translations.
129 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contribution Guidelines
2 |
3 | Thank you for your interest in contributing to **OpenWebUISimpleDesktop**!
4 | We welcome contributions of all kinds, including bug reports, feature requests, documentation improvements, and code changes.
5 |
6 | ---
7 |
8 | ## How to Contribute
9 |
10 | ### Reporting Issues
11 |
12 | - Please use GitHub Issues to report bugs or suggest features.
13 | - Provide clear, descriptive titles and detailed descriptions.
14 | - Include steps to reproduce, expected vs. actual behavior, and any relevant logs or screenshots.
15 |
16 | ### Submitting Pull Requests
17 |
18 | 1. **Fork** the repository and clone it locally.
19 | 2. **Create a new branch** for your feature or bug fix: git checkout -b feature/my-new-feature
20 | 3. **Make your changes** following the project’s code style.
21 | 4. **Test your changes** thoroughly.
22 | 5. **Commit your changes** with clear, concise commit messages.
23 | 6. **Push your branch** to your fork.
24 | 7. **Open a Pull Request** against the `main` branch of the original repository.
25 | 8. Fill in the PR template with a description of your changes and any relevant details.
26 |
27 | ---
28 |
29 | ## Code Style and Quality
30 |
31 | - Write clear, maintainable, and well-documented code.
32 | - Follow existing coding conventions and patterns used in the project.
33 | - Ensure your code passes any existing linting and formatting checks.
34 |
35 | ---
36 |
37 | ## Testing
38 |
39 | - Please test your changes locally before submitting.
40 | - If adding new features, include tests if applicable.
41 |
42 | ---
43 |
44 | ## Communication
45 |
46 | - Be respectful and courteous in all interactions.
47 | - Respond promptly to review comments and feedback.
48 | - If you need help or guidance, don’t hesitate to ask.
49 |
50 | ---
51 |
52 | ## License
53 |
54 | By contributing, you agree that your contributions will be licensed under the project’s MIT License.
55 |
56 | ---
57 |
58 | Thank you for helping make OpenWebUISimpleDesktop better!
59 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2025 n1kozor
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | 
2 |
3 |
4 | # OpenWebUISimpleDesktop
5 |
6 | **OpenWebUISimpleDesktop** is a minimal, modern Electron desktop wrapper for [OpenWebUI](https://github.com/open-webui/open-webui).
7 | It provides a native desktop experience with native window controls and seamless integration, packaged as a simple Electron app with a built-in setup wizard.
8 |
9 | ---
10 |
11 | ## Features
12 |
13 | - Clean, lightweight Electron shell for OpenWebUI
14 | - Built-in first-launch setup wizard to configure app name and OpenWebUI server URL
15 | - Settings saved to `config.json` beside the executable for easy user customization
16 | - Native window controls (minimize, maximize, close)
17 | - Customizable window size, colors, and UI offsets via config
18 | - Displays a connection error message with retry button if the server is unreachable
19 | - Cross-platform support: Windows and macOS
20 | - Easy development with Node.js and Electron
21 | - Crtl + Shift + Space Short. Open a Chat Modal
22 |
23 |
24 | 
25 |
26 | ---
27 |
28 | ## Prerequisites
29 |
30 | - [Node.js](https://nodejs.org/) (v18 or newer recommended)
31 | - [npm](https://www.npmjs.com/) (comes with Node.js)
32 | - A running instance of [OpenWebUI](https://github.com/open-webui/open-webui) accessible via HTTP (e.g. `http://localhost:8080`)
33 |
34 | ---
35 |
36 | ## Installation
37 |
38 | 1. Clone or download this repository.
39 | 2. Navigate to the project folder in a terminal.
40 | 3. Install dependencies by running:
41 | `npm install`
42 |
43 | ---
44 |
45 | ## Configuration
46 |
47 | All settings are stored in `config.json` under the user data directory:
48 | - Windows: `%AppData%/config.json`
49 | - macOS: `~/Library/Application Support/config.json`
50 | - Linux: `~/.config/config.json`
51 |
52 | ### Example `config.json` content:
53 |
54 | ```json
55 | {
56 | "iconDarwin": "assets/ico.icns",
57 | "iconWin": "assets/ico.ico",
58 | "bgColor": "#fff",
59 | "borderRadius": 0,
60 | "profileNavOffset": 15,
61 | "sidebarOffset": 15,
62 | "apiToken": "your_openwebui_api_key",
63 | "windowButtons": "right",
64 | "window": {
65 | "width": 1200,
66 | "height": 800,
67 | "minWidth": 500,
68 | "minHeight": 400
69 | },
70 | "appName": "YourAppName",
71 | "webuiUrl": "http://localhost:8000",
72 | "preloaderTheme": "dark", //or light
73 | "opacity": 1
74 | }
75 | ```
76 |
77 | `webuiUrl`: The URL where your OpenWebUI server is running.
78 | `windowButtons`: Position of window control buttons, `"right"` or `"left"`.
79 |
80 | Adjust icon paths if you customize icons.
81 |
82 | ---
83 |
84 | ## Fine-Tuning UI Offsets in `config.json`
85 |
86 | Adjust these values to fix UI margins/offsets in OpenWebUI's webview:
87 |
88 | - `profileNavOffset`: 15
89 | - `sidebarOffset`: 15
90 |
91 | Typical values range from 10 to 20 depending on your theme and UI.
92 |
93 | ---
94 |
95 | # First Launch Setup Wizard
96 | ## Enter the Application Name
97 | 
98 |
99 | ## Enter the OpenWebUI Server URL (defaults to `http://localhost:8080`)
100 | 
101 |
102 | ## Click Start to save and launch the app
103 | 
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 | On first launch, a simple, clean wizard appears asking you to:
112 | - Enter the Application Name
113 | - Enter the OpenWebUI Server URL (defaults to `http://localhost:8080`)
114 | - Click Start to save and launch the app
115 |
116 | ---
117 |
118 | ## Connection Error Handling
119 |
120 |
121 | If the app cannot connect to the OpenWebUI server, it displays a clear Connection error message with:
122 | - Instructions to check your `config.json` settings
123 | - A Refresh button to retry connecting without restarting the app
124 |
125 |
126 | 
127 |
128 |
129 | ---
130 |
131 | ## Usage
132 |
133 | ### Development Mode
134 |
135 | Run the app in development mode with:
136 |
137 | `npx electron main.js`
138 |
139 | This will start the app loading local files and allowing you to develop and test.
140 |
141 | ---
142 |
143 | ### Build Distributable
144 |
145 | To build a Windows or macOS installer/package using electron-builder, run:
146 |
147 | `npm run dist`
148 |
149 | - Output installers are created inside the dist folder.
150 | - Packaging settings are in package.json under the "build" key.
151 |
152 | ---
153 |
154 | ## Troubleshooting
155 |
156 | - Blank window or connection refused:
157 | Make sure your OpenWebUI server URL in config.json is correct and your OpenWebUI server is running and reachable.
158 |
159 | - Config file not found after wizard:
160 | The config.json file is saved next to the executable. Ensure the app has write permissions to its folder.
161 |
162 | - Icons missing:
163 | Verify icon files exist at the paths set in config.json or update paths to your custom icons.
164 |
165 | ---
166 |
167 | ## Credits
168 |
169 | - OpenWebUI
170 | - Electron
171 |
172 | ---
173 |
174 | Enjoy using OpenWebUISimpleDesktop!
175 |
--------------------------------------------------------------------------------
/assets/ico.icns:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/n1kozor/OpenWebUISimpleDesktop/eaf802f43e10ca73938e86254bd8ffee7fbe9d26/assets/ico.icns
--------------------------------------------------------------------------------
/assets/ico.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/n1kozor/OpenWebUISimpleDesktop/eaf802f43e10ca73938e86254bd8ffee7fbe9d26/assets/ico.ico
--------------------------------------------------------------------------------
/assets/ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/n1kozor/OpenWebUISimpleDesktop/eaf802f43e10ca73938e86254bd8ffee7fbe9d26/assets/ico.png
--------------------------------------------------------------------------------
/config_example.json:
--------------------------------------------------------------------------------
1 | {
2 | "iconDarwin": "assets/ico.icns",
3 | "iconWin": "assets/ico.ico",
4 | "bgColor": "#fff",
5 | "borderRadius": 0,
6 | "profileNavOffset": 15,
7 | "sidebarOffset": 15,
8 | "apiToken": "your_openwebui_api_key",
9 | "windowButtons": "right",
10 | "window": {
11 | "width": 1200,
12 | "height": 800,
13 | "minWidth": 500,
14 | "minHeight": 400
15 | },
16 | "appName": "TestApp",
17 | "webuiUrl": "http://localhost:8080",
18 | "opacity": 0.9
19 | }
--------------------------------------------------------------------------------
/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |