---
title: "Deploy Firefox 160 Cloud Browser in Your Browser"
description: "Mozilla Firefox streamed to a browser tab, with a login and saved profile."
category: "Other"
url: https://railway.com/deploy/firefox-160-cloud-browser-in-your-browse
---

# Deploy Firefox 160 Cloud Browser in Your Browser

Mozilla Firefox streamed to a browser tab, with a login and saved profile.

**[Deploy Firefox 160 Cloud Browser in Your Browser on Railway](https://railway.com/template/firefox-160-cloud-browser-in-your-browse)**

Machine-readable deploy manifest (JSON, validated by TemplateCI): https://railway.com/deploy/firefox-160-cloud-browser-in-your-browse/manifest.json

- **Creator:** Tracklayer
- **Category:** Other
- **Total deploys:** 1

## Template content

### Browser https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/svg/firefox.svg

- **Source:** baranberkay96/firefox-browser-railway
- **Health check:** /healthz
- **Public domain:** Yes

## Documentation

# Deploy and Host Firefox Cloud Browser with Railway

Mozilla Firefox running on Railway and streamed into a tab of your own browser. It opens behind a generated password, and the Firefox profile (bookmarks, history, add-ons, saved logins, downloads) lives on a persistent volume, so it survives redeploys. The browser is Mozilla's own release build, unmodified.

## About Hosting Firefox Cloud Browser

A browser in a tab needs a display session, a streaming server, a login in front of it and storage for the profile. This community template builds on the linuxserver.io Selkies base image (Debian 13, labwc Wayland session) and installs the Firefox 160.0.1 release tarball from Mozilla's archive, checked against Mozilla's SHA-256 list. Selkies streams the screen and sound over one HTTPS WebSocket. Railway runs its own init as PID 1, which the image's s6-overlay init refuses, so a small start script brings up the image's services under s6 supervision instead. nginx asks for a login on every page except `/healthz`. `/config` (the home directory with the Firefox profile) is a Railway volume.

## Common Use Cases

- Use one persistent Firefox, with your bookmarks and add-ons, from any computer, tablet or phone
- Test websites in Firefox's Gecko engine from a server in another region
- Open unknown links and files in a remote browser instead of on your own device
- Keep long-running web sessions and dashboards open while your own computer is off

## Dependencies for Firefox Cloud Browser Hosting

- One service built from a small Dockerfile on top of `ghcr.io/linuxserver/baseimage-selkies` (no database, no external API keys)
- A Railway volume mounted at `/config` for the Firefox profile

### Deployment Dependencies

- [Mozilla Firefox releases](https://ftp.mozilla.org/pub/firefox/releases/)
- [linuxserver/docker-baseimage-selkies](https://github.com/linuxserver/docker-baseimage-selkies)
- [Selkies configuration reference](https://docs.linuxserver.io/selkies/user-guide/configuration/)
- [Selkies web client guide (sidebar, clipboard, files)](https://docs.linuxserver.io/selkies/user-guide/web-client/)
- [Firefox enterprise policies](https://mozilla.github.io/policy-templates/)
- [Railway Fair Use Policy](https://railway.com/legal/fair-use)

### Implementation Details

| Service | What runs inside | Volume | Port |
|---|---|---|---|
| Browser | Firefox in a labwc Wayland session, D-Bus, audio, Selkies (loopback only), nginx (login, `/healthz`), all supervised by s6 | `/config` | 3000 (public HTTPS domain) |

**Plan:** Hobby or higher is recommended. Measured on Railway: about 0.65 GB RAM with Firefox open and nobody connected, 1–2 GB while browsing with several tabs, near-zero CPU at idle. Trial's 1 GB per service fits only a few light tabs; Railway restarts the service when it runs out of memory. Image: about 1 GB compressed.

**First login**

1. Wait for the deploy to turn healthy (the first build pulls a 1.1 GB base image, so allow a few minutes).
2. Open the public URL. Your browser asks for a login.
3. User `firefox` (or your `CUSTOM_USER`; letters, digits and `. _ @ -` only, otherwise it stays `firefox`), password = `PASSWORD` from the service Variables tab.
4. Firefox appears and resizes to your window. The Selkies side menu has the clipboard box, file upload and download, audio, keyboard and display settings.
5. If you close Firefox, right-click the empty screen and choose Firefox to open it again.

**Start page and flags**

Set `FIREFOX_CLI` to a start URL and/or Firefox flags, for example `https://example.com`, and redeploy.

**Security**

- The browser never runs without a login. Basic auth is on in nginx at build time, and if `PASSWORD` is empty, shorter than 8 characters or longer than 256 bytes, the login is locked with a random password and the deploy log says so (use 12 or more characters).
- Only a hash of the password is stored, and the password is removed from the environment before Firefox starts.
- Requests from other websites are refused (Origin check in nginx and Selkies), so a page you visit cannot use your cached login to drive the browser.
- Anyone with the password controls the browser and every account you are signed in to in it. The right-click menu also has a terminal, where the Linux user `abc` has passwordless sudo. The image's `HARDEN_DESKTOP=true` option disables sudo and terminals.
- Railway containers cannot create user namespaces, so Firefox runs its content processes with a reduced sandbox. Treat the whole container as the security boundary and avoid untrusted downloads.
- Browsers keep basic-auth logins until they close. Use a private window on shared computers.

**What persists**

Everything in `/config`: the Firefox profile (bookmarks, history, cookies, add-ons, saved passwords, settings) and downloads. A stale profile lock left by the previous container is removed at start, so Firefox never reports "already running" after a redeploy. Packages installed with `sudo apt install` reset on every redeploy; list them in `APT_PACKAGES` (for example `fonts-noto-cjk`) and they are reinstalled in the background after each start.

**Updates**

Firefox's built-in updater is switched off by an enterprise policy, because the program files are rebuilt from the image on every deploy. The version is pinned in `services/browser/Dockerfile` (`FIREFOX_VERSION` and `FIREFOX_SHA256`). Mozilla ships a new release every four weeks: update both values from Mozilla's `SHA256SUMS` and redeploy. The profile is kept.

**No GPU: software rendering**

Railway has no GPUs. Pages are drawn on the CPU, and Selkies encodes the video stream on the CPU. Browsing, web apps and office tools run well; WebGL, 3D and high-frame-rate video are slow. Lower the frame rate in the side menu, or set `SELKIES_FRAMERATE`, to save CPU.

**Audio and clipboard**

- Sound streams to your browser over the same WebSocket. Browsers only play it after you click in the page once.
- Text copy and paste works both ways. In Firefox and Safari on your side, use the clipboard box in the side menu.

**Fair use**

Use this browser for your own browsing and for testing websites. Railway's Fair Use Policy forbids operating proxies, VPNs or anonymization services, scraping that violates websites' terms, and abusive bots, as well as cryptocurrency mining and reselling compute. Do not share the login or offer the browser as a service to others. Websites may treat traffic from a data-center IP differently (extra captchas, region checks).

**Scaling and limits**

One user, one volume: run one replica and scale it vertically. No WebRTC/UDP (the WebSocket stream is used instead), no Docker, and open tabs restart on every redeploy (Firefox offers to restore the session). Railway's app sleeping stops the browser as well.

### Why Deploy Firefox Cloud Browser on Railway?

Railway gives the browser HTTPS, a persistent volume and usage-based billing without a server to manage. You get your own Firefox at a URL in a few minutes, pay for the RAM and CPU it actually uses, and can resize or redeploy it from the dashboard. Firefox and the Firefox logo are trademarks of the Mozilla Foundation. This is a community template, not affiliated with or endorsed by Mozilla, linuxserver.io, the Selkies project or Railway.


## Similar templates

- [Rocky Linux](https://railway.com/deploy/rocky-linux) — Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀
- [Foundry Virtual Tabletop](https://railway.com/deploy/X5tR6G) — Self-hosted virtual tabletop for role-playing games (license required)
- [Double Commander in your browser](https://railway.com/deploy/double-commander-in-your-browser) — The Double Commander file manager in the cloud, from any device

Open this page in a browser: https://railway.com/deploy/firefox-160-cloud-browser-in-your-browse
