Meaning: To retaliate with a similar form of attack that has been used against you.
This phrase is believed to have originated with firefighters, who will literally fight fire 
with fire depending on what method the situation calls for.

That's right, simply using water is not always the ideal solution. In fact, there are several approaches for extinguishing a flame. One of the techniques firefighters may use, depending on the circumstances, is literally what this phrase states: they will fight fire by making their own fire!

This technique is called backfiring, and is typically utitlized to help control violent forest fires. The strategy, from what I understand, is to intentionally set a fire in front of the oncoming primary fire in order to create a "roadblock" of sorts. By burning away the nearby timber, the primary fire will have nothing left to fuel itself once it reaches that burnt out area, thus crippling the primary fire from advancing any further.

This idiom goes back to at least the mid to late 19th century, as it's written in plenty of newspapers from that time. One of them, for example, is The Rock County Recorder from the 1870s, where it reads:

    "Some one has suggested that it might be proper to fight fire with fire on the prairies, but it would 
     hardly answer to attempt this in an oil refinery."
F-Letter Expressions  |  
* My friend raised her voice and was yelling at me, so I decided to fight fire with fire by also raising my voice and yelling back! It only made things worse, but in the end, we both apologized.
Origins for the idiom Fight Fire With Fire.

A red fire truck.
Note: The above is an example of an idiom. If you want to see the meanings for more idioms, then remember we have an alphabetical list of them that's only a click away. If you are unable to find a particular one that you're looking for, then consider checking back another time, because more common expressions will be added later. Maybe even drop me an email with the expression you had in mind, if you want to.

Anyways, thanks for visiting!
A list of phrases starting with the letter - F.
Phrases and Idioms

Fight Fire With Fire