Skip to content
RetrorerrPublic

About

A real Linux desktop on your Android tablet: Debian 13 and KDE Plasma 6, GPU-accelerated, no root.

Topics

Resources

Contributing

Security policy

Stars

26 stars

Watchers

0 watching

Forks

Repository files navigation

Portal

Portal

A real Linux desktop on your Android tablet. Debian 13 and KDE Plasma 6, no root, no PC, no streaming.

Latest release Android build GPL-3.0 ARM64

Download Portal

Portal running KDE Plasma with the Cloud Dark rice on a OnePlus Pad 3

Portal installs Debian on your device and runs the full KDE Plasma desktop right on the screen, with GPU acceleration, sound, your keyboard and mouse, and the Android clipboard all hooked up. It's everything running locally, not a remote desktop or a VNC window.

Portal is a fork of Local Desktop, rebuilt around Debian, Plasma 6 and a GPU-accelerated KWin. See Credits.

Firefox showing Portal's GitHub page Dolphin showing the Stuff folder with the Cloud Dark rice applied
Firefox Dolphin and the Stuff folder

Kerbal Space Program in a window on the Plasma desktop, a rocket lifting off

Kerbal Space Program from Steam, an x86-64 Linux game running through Box64

Screenshots from a OnePlus Pad 3.

What you need

Portal is made for Android tablets with a Snapdragon chip. That's where it's built and tested, and where it runs best.

  • Tested on: OnePlus Pad 3 (Snapdragon 8 Elite, Adreno 830). This is the main test device. If you try another one, tell us how it went.
  • Should work on: other 64-bit (arm64) Android devices with a Qualcomm Adreno GPU. The GPU path goes through Mesa's freedreno and Turnip drivers, which cover recent Adreno chips. Most of them are untested, so reports are welcome.
  • Other GPUs (Mali, PowerVR, Xclipse): GPU acceleration is built around Adreno, so these get Portal's slower fallback renderer at best. Untested so far; proper support is planned.
  • Storage: around 6 GB free. Debian itself is about a 1 GB download.
  • RAM: more is better. Firefox and a few apps run comfortably with 8 GB or more.
  • Nice to have: a keyboard and mouse or trackpad. Touch works, but a desktop is much easier to use with them.

No root, no PC and no unlocked bootloader needed.

Getting started

  1. Tap Download Portal on your tablet and install the APK (allow installs from your browser if Android asks). Older versions are on Releases.
  2. Open Portal, pick a theme and interface size, and tick any extra apps you want.
  3. Tap Begin Install. Portal downloads Debian and sets everything up, which takes a couple of minutes on a fast connection. You can leave the app while it works.
  4. When it's done, swipe up to enter your desktop.

If setup gets interrupted, just open Portal again. It picks up where it left off.

The user guide covers updates, games, Firefox and troubleshooting in more detail.

Using Portal

  • Coming back: leaving Portal keeps the desktop running in the background. Open it again and swipe up to jump back in, with your windows right where you left them. Swiping Portal away from recents closes the desktop.
  • Logging out (or shutting down or restarting from Plasma) closes the desktop and Portal with it. Open Portal again to start a fresh session.
  • The Stuff folder: your desktop starts with stock KDE Plasma and a folder called Stuff. Inside there's a link to this repo, a short welcome note, and CloudDarkRice, an optional dark theme with a top bar, a dock, a nicer power menu and a bunch of shortcuts. Open the folder, run Apply Cloud Dark rice and log out once it's done. It downloads about 25 MB the first time. Don't like it? apply-portal.sh restore puts everything back (the README in that folder has the details).
  • Managing apps: leave the desktop and come back to Portal's start screen to add or remove the optional apps whenever you like.
  • Updates: the same screen shows updates for Portal, its graphics driver layer, ChatGPT and Debian packages. Tap the capsule, then Update. Portal updates itself from 2.5.0 on; on 2.4.x, install the latest version once with the Download Portal button.
  • Keyboard and mouse: plug them in (USB or Bluetooth) and Plasma switches from tablet mode to desktop mode by itself. Trackpad scrolling works too.

What you get

Out of the box: Firefox, Discover (app store), Dolphin (files), Konsole (terminal), Kate (text editor), Okular (documents), Gwenview (images), Ark (archives), KCalc and System Settings. Handy command-line tools are included too: git, htop, nano, curl, ping, man and friends.

Optional apps (pick them during setup, or add and remove them later from the apps panel when you return to Portal): Claude, ChatGPT, LibreOffice, Thunderbird, GIMP, Krita, Inkscape, VLC and Steam.

Anything else you can get from Discover, which installs Debian packages and Flatpak apps from Flathub, or the normal Debian way. You're the desktop user and sudo works without a password:

sudo apt update
sudo apt install gnome-calculator

Third-party .deb files and APT repos work too, as long as they're arm64. Flatpak apps run with their normal sandbox and GPU acceleration. Graphical apps show up in the Plasma launcher after you install them.

Gaming

Pick Steam during setup and you get the ARM64 Steam client running natively.

  • Native ARM64 Linux games run directly.
  • x86 Linux games run through Box64 (Kerbal Space Program works, for example).
  • Windows games through Proton and FEX are early days, so expect hit and miss. Portal prefers Proton Experimental (ARM64) when it's installed.
  • Controllers connected to Android show up in Steam as Xbox controllers.
  • While Steam runs, a small handle at the top of the screen (drag it wherever you like) shows the on-screen controller (while a game is running) and opens the game panel, where you can edit the controller layout and set a frame-rate cap, per game if you like.

Good to know

  • Keyboard shortcuts and background running: Android can swallow shortcuts like Alt+Tab or Ctrl+C before they reach Linux. Turn on Portal under Android Settings → Accessibility → Downloaded apps to fix that. It only forwards key presses and doesn't read anything on screen. As a bonus, Android treats Portal as a visible app while the switch is on, so it's far less likely to close the desktop in the background. Portal's start screen shows a tip while it's off.
    • If the switch is greyed out, open Portal's App info, tap ⋮ and choose Allow restricted settings. Android 13 and newer does this for apps installed outside an app store.
  • Tablet or desktop: with no keyboard or mouse plugged in, Plasma switches to tablet mode and the Android keyboard pops up when you tap a text field. Plug in a keyboard and mouse and it goes back to desktop mode.
  • Sound goes through Android, and pausing and resuming Portal doesn't break it. You might notice a "Portal Audio (standby)" device in the volume list. That's what keeps apps connected while Portal is in the background, so leave it be.
  • Video: on Snapdragon tablets, Firefox, Chromium and mpv decode video in hardware through Android's decoders, which keeps 4K YouTube smooth.
  • Camera and microphone: Linux apps can use the tablet's cameras and microphone (video calls in Firefox, for example). Android asks for permission the first time an app opens one.
  • Your Android files: grant All files access if you want to open shared storage (Downloads, Pictures and so on) from Linux. Debian itself lives in Portal's private storage.
  • Browsers: Firefox, Chromium and Electron apps run with their normal sandboxes on, no --no-sandbox needed. The Firefox you get is Mozilla's own build from Mozilla's APT repo, and Portal sets up any Firefox you install automatically.
  • Uninstalling Portal deletes the whole Linux install, so copy out anything you care about first.

Known limitations

  • There's no systemd, so systemctl, timedatectl, hostnamectl and friends don't work. Apps that only run as systemd services need starting by hand.
  • Android can pause or kill apps in the background, so long downloads or builds are safest with Portal on screen. Turning on Portal's accessibility switch (see above) helps a lot.
  • If the whole desktop suddenly vanishes under heavy load, Android's child-process limit is the likely cause. Some devices let you turn it off under Developer options → Disable child process restrictions.
  • Only arm64 packages install with apt. x86 programs need Box64 or FEX.

Something broke?

Open the floating pill on the desktop and tap Report. It shows the device details it will fill in, can save your logs to attach, and opens a ready-made GitHub issue for you to finish. Portal uploads nothing on its own, and posting needs a free GitHub account.

If Plasma or setup fails, the recovery screen has Export diagnostics and Report this on GitHub. Exported logs have file paths, web addresses, emails and IP addresses removed where Portal can spot them, and they leave out your personal files. Apps can print anything, so look them over before posting.

Prefer to write it up yourself? Open an issue with your device, Android version, Portal version and what happened.

Running Portal on another device?

Portal is mainly tested on one tablet, so results from other devices are what let it support more of them. Open the floating pill, tap Report, then Share what works, and pick how each part did. "It all works" is just as useful as a bug.

How it works

Android (display · touch · keyboard · audio · clipboard · files)
   │
Portal app (Rust host + Compose screens)
   │  GPU frames: KWin → Mesa (freedreno / Turnip) → Android buffers
   │
Debian 13 under tawcroot (rootless)
   │
KDE Plasma 6 and your Linux apps

Debian runs under tawcroot, Portal's rootless engine: it translates Linux file paths and permissions inside each process, so nothing needs root. Older kernels fall back to a patched PRoot. Plasma's compositor (KWin) renders on the GPU through Mesa and hands finished frames straight to Android, with no copying and no VNC in between. A simpler Smithay-based renderer stays in as a fallback. Audio runs through PipeWire, with an Android AAudio output on the other end.

More detail: architecture, Debian provisioning, user guide.

Building it yourself

You'll need Rust, the Android SDK and NDK, and the vendored xbuild:

git clone https://github.com/Retrorerr/Portal.git
cd Portal
cargo install --path patches/xbuild/xbuild --force
x build --release --platform android --arch arm64 --format apk

On Windows, ./scripts/build_android_variants.ps1 builds both app variants in one go:

  • Portal (app.polarbear.portal) is the normal app. Its build comes out unsigned, so sign it before installing.
  • Portal Debug (app.polarbear) has extra diagnostics and a badged icon, and installs alongside Portal with its own separate Debian.

There's also an on-device Termux build: bash scripts/build-termux.sh.

Before sending changes, run the host checks:

cargo test --tests

Format only the files you changed with rustfmt, since cargo fmt --all rewrites files you didn't touch.

See CONTRIBUTING.md for the rest, and SECURITY.md for reporting security issues privately.

Credits

Portal is a fork of Local Desktop, and its history and GPL-3.0 license are kept intact. The GPU path builds on lfdevs' Anland KWin work and Mesa's freedreno and Turnip drivers. Hardware video builds on lfdevs' termux-va and Mesa for Android containers, and termux-va's daemon derives from droidspaces-media-decode.

App names and logos shown in Portal (Firefox, LibreOffice, ChatGPT, Claude and others) belong to their owners. Portal only uses them to show which apps it installs and isn't affiliated with any of them. Icon sources and licenses are in third_party/app-icons.

About

A real Linux desktop on your Android tablet: Debian 13 and KDE Plasma 6, GPU-accelerated, no root.

Topics

Resources

Contributing

Security policy

Stars

26 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages