VirtualBox Access Client Http Server From Host

Sep 27, 2020

Setup Host-only Adapter.

NOTE: You might want to consider Static IP as well.

On Ubuntu Client, setup hosts file.

nano /etc/hosts
192.168.56.101  virtualbox.local

When you launch a http server, do bind to host virtualbox.local instead of 127.0.0.1 or localhost.

  • Python Webserver: python3 -m http.server --bind virtualbox.local 8000
  • Nuxt Dev Server: nuxt --virtualbox.local --port 3000

On Windows Host, setup windows host file.

192.168.56.101 virtualbox.local

From Windows Host, open browser and access the client's http server via http://virtualbox.local:3000/

❤️ Is this article helpful?

Buy me a coffee ☕ or support my work via PayPal to keep this space 🖖 and ad-free.

Do send some 💖 to @d_luaz or share this article.

✨ By Desmond Lua

A dream boy who enjoys making apps, travelling and making youtube videos. Follow me on @d_luaz

👶 Apps I built

Travelopy - discover travel places in Malaysia, Singapore, Taiwan, Japan.