If you use Firefox, you can install something like Blender (https://addons.mozilla.org/it/firefox/addon/blender-1/) which fakes your data to some common data (to make you "blend" in the crowd).
Now I digress, but I suggest disabling (or use click2play) plugins, as they leak a lot of informations about you.
For cookies (which are used a lot for tracking), you can install something like Self-Distructing Cookies (https://addons.mozilla.org/it/firefox/addon/self-destructing...), which accept cookies (like most browsers do), but delete them when you close the tab.
Don't forget something like RefControl (https://addons.mozilla.org/it/firefox/addon/refcontrol/)/ Smart Referer (https://addons.mozilla.org/it/firefox/addon/smart-referer/), as the referer can be used to track you.
And the classic Disconnect.me (https://www.disconnect.me/) or AdBlock + EasyPrivacy (https://easylist.adblockplus.org/en/).
See, privacy/anonymity on the web requires a lot more than just disabling the useragent. There are several other ways to track you, and it might have some legit uses (for example, serve you the right software for your operative system, I don't think there's a javascript api to recognize your os). It might be a good start, but it wouldn't help a lot, and it would break a lot of legacy code.
https://panopticlick.eff.org/self-defense.php has some strategies.
Disabling referer may break downloads and images on many sites. You'd think they'd all be able to support blank or non-existent referrers, but many large CDNs only support whitelisting specific REFERER strings (not blank ones). We'll be turning referrer blocking back on for one of my big sites shortly because we have other sites linking directly to file downloads (of 60MB and up) and hotlinking images.
HTML5 media is my favorite example of this: mobile devices will actually straight up lie to you when you call certain methods.
If you're making even moderate use of any HTML5 features, you're going to end up doing user agent sniffing.
Anyway, feature testing and benchmarking can be used to create a user agent fingerprint. Hiding the user agent header just keeps it "secret" for a few weeks until the big trackers all switch to fingerprinting.
Just give up on hiding identifying information. The promiscuous model used by web technologies is not securable. For instance, timing analysis can be used to determine which sites you have recently visited.
I'd like to get to the point where the only identifying information my computer gives out about me is information I give out about myself.
At the end of the day I shouldn't even suffer as a user because of this because if sites are "doing things right" then they shouldn't be using the user agent for anything at all anymore. They should be using feature testing only.
Since it's been such a useless feature for so long, I'm surprised no browser makers have gone as far as removing it entirely (I'm looking at you chrome and firefox)