I usually get stress headaches, so I don't consider them good because they are a result of my high stress levels which I already have a hard time keeping down anyways. If a headache is caused by good mental progress, and it results in bad high stress levels (sometimes panic attacks), then to me, it just evened itself. Ibuprofen is my friend.

That is a very positive outlook though, so go with what works. The happier the better.