Skip to main content

['Website As App v1.3.1 * Copyright 2023-2024 by Marcin Orlowski.', 'Opens any web site as standalone desktop app.', 'https://github.com/MarcinOrlowski/website-as-app/']

Project description

WebApp

WebApp

Run any website as standalone desktop application


This Python package offers a unique approach to web browsing by opening any webpage in a dedicated window using the embedded QT WebEngine. By removing the typical browser UI elements, it effectively turns websites into standalone desktop applications. This can be particularly useful if you've ever wished to run a frequently used website as a separate app, independent from your main browser. The embedded website can access your clipboard, so all the "Copy" buttons from various generators or chats works as expected. You can also upload and download files as you'd in any other application.

The tool provides a practical solution for those who find themselves juggling numerous browser tabs or wanting a clearer separation between work and personal web applications. With each website running as its own "app", you gain the benefit of individual entries in your window manager or task switcher, potentially improving your workflow organization and efficiency.

Whether you're looking to streamline your digital workspace or simply curious about alternative ways to interact with web content, this script presents an interesting concept that might just solve a problem you didn't know you had.

IMPORTANT: It's worth pointing out however, that this tool doesn't transform websites into offline applications. Rather, it focuses on separating your key websites from each other and from the multitude of browser tabs you might typically have open. While this approach offers improved organization and workflow, it's crucial to understand that an internet connection is still required for these "apps" (websites) to function as they normally would in a traditional browser environment.

Installation

This is regular Python package and is also hosted on PyPi so you can install it as usual. But because this one is supposed to rather act as the application, I strongly recommend to use pipx to install this tool in isolated environment:

$ pipx install website-as-app

You can also use plain pip:

$ pip install website-as-app

But that might be a problem on some distributions no longer allowing such installations, therefore use of pipx is strongly recommended as the all-in-one solution.

Once installed webapp executable (and its alias runasapp) should be available in your system. Please use --help to see all available options, as i.e. custom icons, window title etc.

Usage

When app is installed system-wide, you can run it from anywhere:

$ webapp "https://github.com"

If you are using virtual environment, there's handy Bash script in extras/ directory which takes care of initializing virtual environment and running the app using that environment. You simply use extras/webapp.sh script instead of webapp directly:

$ extras/webapp.sh "https://github.com"

Configuration

Available options:

webapp -h
usage: webapp [--profile PROFILE] [--name NAME] [--icon ICON] [--zoom ZOOM] [--no-tray] url

Open any website in standalone window (like it's an app)

positional arguments:
url                   The URL to open

options:
--profile PROFILE, -p PROFILE     Profile name (for cookies isolation etc). Default: "default"
--name NAME, -n NAME              Application name (shown as window title)
--icon ICON, -i ICON              Full path to PNG image file to be used as app icon
--geometry GEOMETRY, -g GEOMETRY  Initial window ("WIDTHxHEIGHT+X+Y"). Default: "450x600+0+0"
--zoom ZOOM, -z ZOOM              WebView scale. Default: 1.0 (no scale change).
--no-tray, -t                     Disables docking app in system tray (closing window quits app)
--minimized, -m                   Starts app minimized to system tray.
--allow-multiple, -a              Allows multiple instances of the app to run on the same profile
--debug, -d                       Makes app print more debug messages during execution

The most important option is --profile which allows you to isolate cookies and app settings per instance. Any instance using the same profile will have access to the same cookies and settings. This is useful if you want to run multiple instances of the same app, but with different accounts. By default default profile is used and it's recommended to use different profile per each app instance.

By default only one instance per profile is allowed to run (attempt to run second instance will bring the first one to the front). If you want to allow multiple instances of the app to run on the same profile, use --allow-multiple switch.

NOTE: --zoom accepts fractional values, so you can use i.e. --zoom 1.25 to scale content up by 25% or --zoom 0.75 to scale down to 75% of the original size.

License

  • Written and copyrighted ©2023-2024 by Marcin Orlowski <mail (#) marcinorlowski (.) com>
  • ResponseBuilder is open-sourced software licensed under the MIT license

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

website_as_app-1.3.1.tar.gz (275.8 kB view details)

Uploaded Source

Built Distribution

website_as_app-1.3.1-py3-none-any.whl (275.9 kB view details)

Uploaded Python 3

File details

Details for the file website_as_app-1.3.1.tar.gz.

File metadata

  • Download URL: website_as_app-1.3.1.tar.gz
  • Upload date:
  • Size: 275.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.3

File hashes

Hashes for website_as_app-1.3.1.tar.gz
Algorithm Hash digest
SHA256 6e9df525d6bb6a4d62deaa31d7f94b748252d804b36242b86261cfdae6a80537
MD5 b7720f378e391c0cbb92f0e8d7a6a7cc
BLAKE2b-256 2f05c245365ae2f0a255d2fe0282bdc903ed8bd8a99848edadc82ef7dd113b07

See more details on using hashes here.

File details

Details for the file website_as_app-1.3.1-py3-none-any.whl.

File metadata

File hashes

Hashes for website_as_app-1.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e77708c1cf47d59fd20f1cd2547c97f0d73b0982e271c05c23a6fd6f394b9f71
MD5 98d0119a5b739b4b81776c8b53bd3dcd
BLAKE2b-256 2657419b908f830a8dde3539254ef1b06ac739666df53e593bdac76f5e8caff9

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page