You have the right to defend yourself from an "interference" with your person, subject to certain conditions. An interference is generally an unwanted touch of some sort. The less the interference, the less right you have to fend it off. The interference must be actual or about to happen. Your evaluation of the situation and what to do about it must be reasonable. Of course you may have little time to weigh what's reasonable. Do what you need to do, but be mindful that someday 12 strangers (a jury) may be reviewing your conduct in hindsight, and they may disapprove of your choices.
Duty to Retreat
There is no duty to retreat, in and of itself. But if you had the opportunity to safely retreat, and recognized it, that becomes a factor in whether your response to an interference will be considered reasonable.
What if You Provoked the Interference in the First Place
If your own conduct provoked the interference, you may lose the right to self-defense. If, however, you then make a good faith effort to withdraw from the ensuing confrontation, but the other party keeps after you, then you may regain the right.
What if You Hurt a Third Party While Defending Yourself
If while defending yourself from one person, you unintentionally hurt another, you may be responsible for injury to that other person, and guilty of a crime arising from that. It will depend on whether your conduct recklessly or negligently created an unreasonable risk to the third person.
Defense of Others and Defense of Property
You also have the right to defend others, similar to the conditional right to defend yourself as described above. You also have the right to defend property, but this comes with one further limitation. In Wisconsin, there is no right to defend property by intentional use of force likely to cause serious injury or death.
As of 2012, Wisconsin has adopted a form of what is commonly known as the "Castle Doctrine." With some restrictions and conditions, this law modifies the above rules and immunizes the defense of one's self or another in one's home, motor vehicle, or place of business. See 895.62, Wis. Stats.