r/HTML • u/SushiSasha003 • Oct 08 '26
Question Running Applications on my Laptop from HTML
Hello! I’m creating my own OS-ish inside of HTML (sorta) for school and I wanted to figure out how to run apps from HTML, but I can’t figure it out for the life of me, can anyone help me out?
On top of that! I’m also struggling on how to open the HTML and have it immediately full screen, if anyone knows how to do it, I would like to know!
Thank you guys so much!
Edit: To add on, I’m not trying to run it inside of the website, I’m just trying to open the program from the website
0
Upvotes
2
u/armahillo Expert Oct 09 '26
This used to be possible, but its been deprecated a for a long time for security reasons. If you could run applications from web pages, this would allow a malicious site to run something on a user’s computer that could compromise it.
2
u/Doffu0000 Oct 09 '26 edited Oct 09 '26
Yes this is completely possible if you're using windows. Look up HTA HTML Application. It's not web-based, runs on your computer, is mostly HTML unless you want to integrate other languages. I use it for work all the time to launch powershell scripts, and hub together all my common applications.
Forgive others for saying this can't be done... HTA is pretty oldschool and not a lot of people know about it.
Other more modern options (but more technical) would be to make web apps. They can run on your desktop and have permissions to launch applications too.
Edit: Just noticed you made an update saying it's to be done from a web-browser which runs you into some permissions issues. Permissions can be given though... but you still need something beyond HTML like a helper program running on the computer to interpret outgoing messages. For instance you could use a web-socket or even something silly like MIDI to send signals from the site, have the helper on the computer interpret them and decide what to do with the signal... in this case launch a specific file. Or you could register custom deeplinks but both these options go quite beyond just HTML.
11
u/Gentoss Oct 08 '26
I guess you missunderstood what HTML is, it's just a language to structure things...
You can't make a car driveable if you only have the structure of it.
1
u/kalilamodow Oct 09 '26
You can't unfortunately :( browsers explicitly sandbox most stuff on the local filesystem for security and things. Although opening a local html file does give a few extra permissions like loading images from the system, it would be a massive security hole to let websites execute local programs.
If you want to look into this more, you can give Electron a shot - it lets you make a native application and write the UI in HTML. Then you can pass a message to the backend to open your application of choice. But it's not really for beginners.
1
u/NetSage Intermediate Oct 09 '26
Sounds like you're trying to make a web app.
https://www.electronjs.org/
Tends to be the go-to option.
1
u/Commercial_Echo923 Oct 09 '26
you can use deeplinks if the apps support it. it works like mailto: links
1
u/Distdistdist Oct 09 '26
Your HTML OS-ish will only run browser applications. Nothing outside your browser is accessible.
1
u/Adamstrad Oct 09 '26
OP, I recommend looking at either python or autohotkey, you can make a user interface with them like a launcher and you can open files on your own computer more easily
1
u/Adventurous_Push_615 Oct 09 '26
Why not run apps in the browser completely using WebAssembly?
1
u/marmotta1955 Oct 09 '26
Not entirely sure but ... even today, even if deprecated, even if not secure ... HTA files allow you to launch applications from HTML pages - just as others have already suggested
1
u/darklordbazz Oct 09 '26
You could use docker containers that run the desktop apps then use a web browser to control the virtual desktop
0
u/Adamstrad Oct 09 '26
You just use the link of the program file as an "a" tag, is that what you mean?
Also html is just a language for formatting a page, it needs to run inside a browser so to do this you need to make your browser full screen, you won't get far making a real operating system but if you want to use it like a menu to find and open things it is doable, you might have to use some other languages though if you want to add calculations and logic
-1
u/krisleslie Oct 09 '26
I think you misunderstand technology