Harwich trains leave from Liverpool Street. It's quite a good service.
From LCY, you can get a shuttle bus direct to Liverpool St.
From LHR, it depends on how much luggage you have. The quickest way, if you don't have much, is to get the HEX to Paddington, then walk to Lancaster Gate and get the Central Line from there.
If you do have luggage, consider a taxi from Paddington to Liverpool St, or the Circle Line from Paddington. If cost is an issue, you can take the Piccadilly Line from Heathrow, changing at Holborn for the Central Line.
From LGW, hmm. Probably the easiest is to catch the Thameslink to Kings Cross, and get the Circle/Met/H&C from there. Otherwise, you could get the Thameslink to London Bridge and cab or bus it.
From STN, it's a royal pain. Although STN is in the right direction, to get the train (realistically), you'd have to head into London (Liverpool St also), and head back out. There's no direct buses, either.
The trains from London are timed to connect with the boats, and so aren't very regular. Go to
http://www.qjump.co.uk/ for details. A standard single is £16.50; a short-period return is not much more.
Note that there is a special port station in Harwich: Harwich International. If your boat is a cruise, it's possible the direct trains won't get you in at the right time, as they connect with scheduled ferries. Don't worry, though, there's a regular connecting service, if you change at Manningtree.