Make sure you talk to the City of Fremont Planning department FIRST ...
They will tell you what can or cannot be done. If they give the go ahead for demolition, then Google â€œFremont CA demolition contractorsâ€ for quotes. This is a real estate forum and we are not in a position to give you estimates for projects like this.
The next question I would ask you, is what do you plan on doing with the property once the structure is demolished? If you are thinking of selling the "lot", you have the option of selling the property with the existing structure intact thereby leaving the responsibility of demolition to the Buyer.
I hope this information is of benefit to you. If you have any other questions, by all means let me know.
I would make sure that you run it by the Planning Department first to see if you can obtain a demolition permit prior to purchasing the property.
If the farmhouse is in shambles, and you aren't given clearance to demo the site, then I would look to HARB to see if the home can be moved or sold by the piece to collectors or demo companies that look to reuse the wood, door knobs and other features first so you could demolish the balance later on.
Again, the first question is whether or not they will allow you to demo the site at all - be sure to check on this first.