App Random Number Generator: Build an Installable RNG for Your Phone
Everyone else searching "random number generator" gets a web form. The word "app" in your query is doing real work: you want something that lives on your home screen, opens full screen, vibrates when it draws, and keeps working on a plane. This guide ships exactly that in under a minute, from one sentence, with no App Store and no signup.
Why "app" changes everything in this search
The SERP for "random number generator" is dominated by sites that treat it as a web form. You land on a page, fill in min and max, click a button, and leave. That is fine if you need one number once. If you need to pull out an RNG repeatedly at a Dungeons and Dragons table, a kids' party, a sales floor raffle, or a stand-up, the form-in-a-tab experience fails: you have to reopen the tab, wait for ads to load, and share your screen because the phone doesn't hold the context.
An app random number generator is different in four concrete ways:
- It has a home-screen icon, so reopening it is one tap.
- It launches in standalone mode: no URL bar, no browser chrome, full screen on the notch.
- It vibrates or clicks when you draw, so it feels physical.
- It works offline, so planes, tunnels, and bad wifi don't matter.
The prompt that builds it
Paste this into mk0r exactly as-is. The specific words matter; each phrase maps to something in the generated HTML.
Build a random number generator as an installable PWA in a single HTML file. One big Draw button, huge result number in the middle. Inputs for min and max (default 1 to 100), and a history strip of the last 10 draws. Make it installable to the home screen: include an inline <link rel="manifest"> using a data URL so there is no separate manifest.json, plus apple-mobile-web-app-capable, an inline SVG apple-touch-icon, theme-color #0ea5a0, and display:standalone. Respect prefers-color-scheme. Use viewport-fit=cover with env(safe-area-inset) padding so it looks right on iPhone notch and Android gesture bars. On Draw, call navigator.vibrate(40) for haptic feedback on Android, and play a short Web Audio click as a fallback for iOS. Request a screen wake lock while the page is visible so the phone does not sleep mid-session. Cache the page with a minimal service worker so it opens offline after the first load.
Every clause in that prompt is load-bearing. Delete the line about viewport-fit and the safe area, and the number will clip under the iPhone notch. Delete the wake lock line and the screen will dim while a kid is about to tap Draw. Keep them.
Build it now
Open mk0r, paste the prompt, wait twenty seconds. Then tap Share and Add to Home Screen on your phone.
Open mk0r →What the single HTML file actually contains
mk0r's Quick mode streams a standalone HTML file in under half a minute. Because it is one file, the usual PWA boilerplate (manifest.json, separate icon PNGs, a service worker file) would be three extra round trips you do not want. The trick is inlining everything. The head of the generated file looks like this:
Two details worth pointing out:
- The manifest is a data URL. A PWA install prompt needs a manifest with name, start_url, display, and icons. Most tutorials tell you to host a manifest.json. You don't have to. Browsers accept a
data:application/manifest+jsonhref on the link tag. One file stays one file. - The icon is inline SVG. Same trick, applied to apple-touch-icon. iOS happily rasterizes the SVG for the home-screen tile. You get a custom icon with no image asset to host.
The script at the bottom of the file wires haptics and the wake lock:
Both APIs have graceful fallbacks built in. No library, no polyfill, no bundler.
Installing it on your phone
mk0r hosts the generated page behind a shareable URL the moment it finishes. Open that URL on your phone and:
- iOS Safari: tap the Share icon, scroll down, tap "Add to Home Screen". The icon you inlined appears on your home grid. Tapping it opens the app with no URL bar and no Safari chrome.
- Android Chrome: a small "Install app" banner usually appears at the bottom automatically. If not, open the three-dot menu and pick "Install app". It installs like a real app, including an entry in the app drawer.
- Desktop Chrome, Edge, Arc: the URL bar shows a little install icon on the right side. Click it and the page opens as its own window, complete with a taskbar or Dock entry.
After the first launch the service worker keeps the page cached; airplane mode, subway tunnels, and kids who delete your wifi no longer matter.
Variants worth building
Swap the body of the prompt, keep the PWA clauses, and you get a different app with the same installable shell:
Lottery quick-pick
Six unique numbers 1 to 49 plus one bonus 1 to 10, big readable digits, tap to reroll, vibrate on draw.
Dice tray
Tap the screen to roll. Shake the phone (devicemotion) to reroll. Buttons for d4, d6, d8, d10, d12, d20. Short haptic on every roll.
Secure PIN generator
6, 8, or 12 digit PIN using crypto.getRandomValues. Big copy button. Shows bits of entropy. No PIN leaves the device.
Raffle drawer
Paste names, hit Draw. No repeats until Reset. Winners list persists in localStorage so closing the app does not lose state. Confetti on draw.
Why not just download a random number app?
The App Store and Play Store are full of RNG apps. Most are wrapped web views with an ad SDK bolted on. They ask for contact access, show an interstitial every third draw, and push a premium upgrade after a week. The whole experience exists because the developer needs to make rent on something that is ultimately one call to Math.random().
An app you generated from a sentence has no publisher behind it, no telemetry, no ad network, and no paywall. It is code you can read, hosted on a page you can fork, installed on your phone with two taps. That is what "app" should have meant from the start.
Frequently asked questions
What is the difference between a random number generator site and an app random number generator?
A site lives inside a browser tab. An app sits on your home screen, opens full screen with no URL bar, runs offline after the first visit, and can talk to hardware features like vibration and the wake lock. For anything you pull out at a party, a tabletop session, or in a meeting, the app version is what you actually want. Most search results for 'random number generator' only give you the site version.
Do I have to publish this to the App Store or Play Store?
No. The page you generate is a progressive web app. On iOS you tap Share, then Add to Home Screen. On Android you tap the three-dot menu, then Install app. It gets its own icon, opens standalone, and stays installed until you delete it. There is no review queue and no developer account.
Does the app work offline?
The single HTML file mk0r generates contains all the HTML, CSS, and JavaScript inline. If you add a one-line service worker in your prompt ('cache the page so it opens offline after the first load'), the browser will keep the page cached and open it with no network. Randomness runs entirely on the device, so offline works exactly like online.
Can the phone vibrate when a number is drawn?
Yes. The generated JavaScript can call navigator.vibrate(40) on Android Chrome and Firefox; iOS Safari ignores vibrate but Web Audio can play a short click that feels similar. Ask for 'haptic feedback on draw' and the code wires both, with a silent fallback where neither is supported.
How is this faster than installing a random number app from the store?
The App Store path is: search, read reviews, install a 20 MB bundle, skip three onboarding screens, hit a paywall, close an ad. The mk0r path is: type one sentence, wait 20 seconds, tap Add to Home Screen. The app weighs a few kilobytes and has no ads and no paywall because there is no company behind it, only you.
Can I make it match my phone's dark mode and safe area?
Yes. Include 'respect prefers-color-scheme, use viewport-fit=cover and env(safe-area-inset) padding so it looks right on iPhone notch and Android gesture bars' in your prompt. The generated CSS will handle both.
Does mk0r require an account?
No. Open mk0r.com, type the prompt, get the app. No signup, no email, no payment. You can install it on your phone immediately.
Build an RNG that lives on your home screen, vibrates when you draw, and works on a plane. One sentence, thirty seconds, no signup.
Build Your RNG App