According to dictionary.com:
attempt
noun, an effort made to accomplish something
So based on this, something like
You needed 4 attempts to hit the target!
would make more sense because the player had to make an effort four times in total.
Now, that might not be the most question to ask. We need to take into consideration the context in which this will be used.
If the fact that they failed many times before succeeding is important in your context, for instance if the "ratio" of "hit" vs "miss" is important because you're keeping stats, you may want to present it with the failed attempts too:
You had 3 failed attempts before hitting. Your score is 25%.
or we could get rid of the concept of "attempts":
You missed 3 times before hitting. Your score is 25%.
Highlighting the fact that they missed 3 times before hitting might help the players see what you want them to see.
In any case, whatever you choose, you should have your game tested by multiple people and see if they understand clearly the information you try to transmit; adapt your user interface as required.
successful attempt
in the header? That kinda anwers the question itsself. Yes it counts as attempt, it is asuccessful attempt
... – some_user Sep 08 '18 at 08:45