How can I use Virtualbox custom NAT and also port forward?

For demos, I am running my VMs behind NAT on my laptop. If I run it in the vanilla NAT mode, then each VM I spin up automatically gets and I can port forward traffic from my host laptop to it (e.g. browse HTTP interface by typing in in my browser).

The problem however comes when I do mutiple VMs at the same time with this native NAT. All of them get as an IP, so they cannot see each other for the demos I am setting up. When I do custom NAT (i.e. a unique 10/172/192 net I create just for my laptop), I unfortunately cannot do port forwarding (not an option in the GUI when I select this networking option in each VM's settings).

I'm hoping to both bridge VMs, use NAT, and port forward from my house. I supposed I could start putting multiple interfaces on them in vanilla NAT so they could see each other on this other internal VLAN I create, but I was hoping there was an easier way.

1 Answer 1


Use different network adapters in different guest vms. For example in the first guest use 'Adapter 1' for NAT, then it assigns and if you use 'Adapter 2' for second guest vm, it assigns

Or else have a look in to this link , you can configure your own custom NAT. https://www.virtualbox.org/manual/ch09.html#changenat

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .