I like to access dark web and i know it is not safe to access through windows. What is the recommended OS to access dark web other than windows. will it affect my anonymity if I use that OS through virtual machine in windows?
my preference is FreeBSD, but if you have ARM SBC like Raspberry Pi - you can use Linux with a last kernel compiled from source - NOT a dpkg/rpm/apt/yum provided one! If you can tell me more about the hardware setup you're using - I can be more specific in recommendations
UPDATE: As I see the hw specs - you will be perfectly fine with virtual machines! I do recommend VirtualBox - grab it and the extension pack. You'll need 2 VMs, one for Tor, one for a "browsing workstation". Tor one will be just fine on 1 CPU and 512Mb of ram, disk 4Gb will fit also, I do recommend Debian mini/netinstall - it is without graphics, and actually a bare OS - just what you need not to waste resources. Browsing VM can use 1 or 2 CPUs, 1Gb of ram - you can use the same iso but select the graphical desktop environment at the installation phase. The trick will be that desktop and the router will be in one virtual(not host-only!) network, so no data leaks will be there. Router will have 2 interfaces - one for a bridge to your actual network card that gives you the connection, it will be just like the one more PC in your network and your router will serve it all by itself just fine. On a desktop VM use Tor's SOCKS port and DNS port - and don't forget to fix the DNS server IP to your tor router VM. That's it!
You must first evaluate your threat model. If you are browsing Tor for fun, Windows is fine. If you are browsing Tor to do something illegal in your area of the world, then you would need to take more precaution.
As a slight aside, this poses potentially an ethical dilemma, I draw the line with providing people advice on how to potentially get away with illegal things, so my only answer is to evaluate your threat model and I will assume your are not doing anything illegal.
I will assume you have valid reasons for paranoia, i.e. are threatened in some way and/or part of a marginalized group that finds themselves at odds with the powers at be.
I would recommend Tails OS. Follow the instructions here. Why Tails? It is a live OS, meaning, as an amnesiac, it cannot leave a trail for those pursuing you.
That doesn't mean you can't be tracked, that just means it is harder to have evidence of it later. ISP's, cell towers, internet backbone infrastructure, etc. all log and likely pass on your requests and metadata to local, national, and international government apparatuses, therefore it behooves you to also ensure DNS is not leaked, you completely ensure anonymity by not visiting real name profiles for yourself, and don't use locations near your place of residence.
Additional precautions: You should also run your own VPN on a VPS, and run your own DNS over HTTPS server if possible. These would add more layers of protection, but again, not fully safe.
Additional additional precautions: Buy a burner laptop and pay as you go cell with cash and use one time. Each time. That is like $200 USD per session if you get a really cheap laptop. Hopefully what you are doing is worth it.
will it affect my anonymity if I use that OS through virtual machine in windows?
yes it can!
- if the host OS is compromised it may be completely pointless what OS you are using in the VM.
- also software is never 100% bug-free... e.g. sooner or later i always experienced critical bugs in sandboxes and (very abridged) you can see a VM more or less as an "advanced sandbox".
long story short: whenever possible, use physical separation!
What is the recommended OS to access dark web other than windows.
beforehand: fiddling around with things you haven't any clue of and just copying & pasting a bunch of random commands is IMHO also a security risk!
well... the best compromise for easy usage and high security would be Tails and if anyhow possible as a live system starting form an DVD. using an USB stick and if necessary a persistent storage may also be an acceptable trade-off for more convenience.
if you still want to stick with a VM, Whonix may be worth a look... but the security risk, host is still pending.
therefore Qubes OS would be the high security solution.
perhaps this answer may also be helpful for you: https://tor.stackexchange.com/a/17458/5234