Question: I have to drive a 12V [solenoid valve](http://www.granzow.com/PDFs/V20153.pdf). In the datasheet it's written: Power: 8 W. So the current drawn by the solenoid is 0.666 A.

Usually, to drive small relay (about 10 or 20 mA) I use a bipolar transistor but with this kind of current is it possible? Or do I have to use a MOSFET because my bipolar will be burning?

Answer: 
I'm afraid I don't agree with Matt's conclusions.

You *can* find BJTs with low saturation voltages. A quick search at Digikey turned up [this one](http://www.onsemi.com/pub_link/Collateral/NSS60601MZ4-D.PDF). At 1 A the saturation voltage is typically 45 mV, that's equivalent to a FET with an \$R\_{DS(ON)}\$ of 45 mΩ. Not bad at all for a BJT.  

And even the 200 mV Matt used as a typical value is absolutely no problem: at 0.67 A that's 130 mW, and the "lot of wasted energy" after a year of continuous operation is 1.17 kWh. For the NSS60601MZ4 that's 0.26 kWh. Not what I call "a lot".

The problem lies elsewhere. The minimum \$h\_{FE}\$ of 120 at 1 A is specified for a \$V\_{CE}\$ of 2 V, i.e. the transistor is *not* in saturation. The 45 mV is for a base current of 100 mA and 1 A collector current. Now *that*'s what I call a waste: the 100 mA doesn't flow through the load at all. If you control the transistor from a microcontroller you'll have the problem that a microcontroller can't source that much current. And, finally, the datasheet notes that the 100 mA is pulsed, so it may not be able to do this continuously (though I couldn't find a maximum value for base current).

That's the problem with BJTs, especially for currents higher than about 0.5 A. And here the MOSFET shines. Drive current: near zero. \$R\_{DS(ON)}\$: what you want to pay for, 1 mΩ is possible. You'll have to look at the minimum gate voltage; for driving by a microcontroller you want a **logic level gate** FET. 

So, if FETs are so great, why do we still use BJTs? Cost. A BJT may be 50 % cheaper than a FET. It's that simple really.

**edit**  

Scott mentions a Darlington to overcome the driving current problem with the BJT. I failed to mention it, and I should have. Not because it's a solution, but because it's not! A Darlington has a (much) higher saturation voltage than a common BJT; I've seen values up to 4 V maximum. But even 1.5 V would be much if you have a low voltage supply like 12 V: the reduced voltage across the solenoid means that only about 75 % of the required 8 W is available, and that may be too little to activate the solenoid. Also, the transistor will dissipate 1 W, and a Darlington is more expensive than a common BJT, so the cost advantage doesn't count either.
BJTs make terrible swtiches. Their Vce is typically around 300mV. That is a specification that is available in the datasheet. MOSFETs typically have a Rds on of less than 100 mOhms, making Vds almost negligible. 

In this case, how much do you care that the entire 12V is dropped across the solenoid? If that is important, a MOSFET is the better option. A BJT could handle the current, but it will be like you're only getting 11.7V across your solenoid valve.

Another consideration is power dissipation, for the same current. In reality the BJT current will be slightly lower due to Vce.

BJT:

\$ P\_q = I \cdot V = 0.666A \cdot 0.3V = 200mW \$

MOSFET

\$ P\_q = I^2 \cdot R\_{ds} = (0.666A)^2 \cdot 50m\Omega = 22mW \$

The MOSFET is 9 times more efficient than the BJT. That may be important if the device in question is under continuous operation.