Sometimes you spend a day or more solving a technical problem, and when you finally solve it, you may want to post it on your blog (if you have one) to share with the community.

However, most developers don't have a lot of time to update their blogs, and that is why personal blogs are not ranked very highly on Google/Bing.

So even if you describe a brilliant idea, chances are that, except a few of your friends, nobody will ever find it. This is a common reason why some developers start their blogs and soon give up; it is not interesting to write for the community if you have no feedback on your posts.

Unlike personal blogs, Stack Exchange sites are highly ranked in Google (I was amazed when I saw that a question asked on SO just an hour ago appeared 3rd in my Google search!), so if your question and answer are valuable for others, they will be rated highly and will be visible for other developers.

With this in mind, is it good practice to post a question and answer it yourself immediately when you want to share an idea with the community?

  • 8
    I think that this would be an excellent idea.
    – bortzmeyer
    Commented Jul 6, 2009 at 11:42
  • That's exactly what I did here: stackoverflow.com/questions/247005/…. I spent hours figuring that one out (including some really obscure blog posts) and figured I could help some other people out too... Turns out a subsequent co-worker of mine found the post, without knowing it was mine, and used it on one of our projects. :) Commented Jul 9, 2009 at 13:52
  • 11
    Not quite a duplicate - this talks about asking and answering a question you already know the answer to
    – Casebash
    Commented Aug 31, 2009 at 23:42
  • Thanks to this and all your posts I'll ask a self-ansewred question with all your suggestions. I answered myself during my redaction and exemplification of my own question. Thanks everyone!
    – Metafaniel
    Commented Mar 8, 2012 at 20:32

10 Answers 10


Having this in mind, is it a good practice to post a question and answer it yourself immediately on stackoverflow/serverfault when you want to share your idea with community?

Absolutely, that is one of the design goals for the site: to be a frictionless technical mini-blog where you get reputation for your hard work.

Since May 2012, you can even write your answer before posting the question: see What is this "answer your own question" jazz? here on Meta, and Encyclopedia Stack Exchange on the blog.



  • 9
    @Jeff This laudable idea only actually works if the question is interesting and the answer is novel. I can only speak for the C and C++ languages on SO, but in practice I have never seen such a post. Almost all of them are of the Q: "how do a copy a string?", A: "I copy it like this" ilk, and seem to be excuses for rep-farming.
    – nb69307
    Commented Jul 6, 2009 at 13:37
  • 19
    The strange thing is, that the questions with an answer by the person asking the question, don't seem to get that many points. Commented Jul 7, 2009 at 5:33
  • @BradGilbert it's probably because it feels like one is pimping themselves. ;)
    – kenny
    Commented Jun 21, 2012 at 22:45
  • 1
    @brad it's important that a) the Q&A is still solving an actual problem, not a made-up hypothetical one and b) the question meets our question standards, it does not get a "free pass" if it is barely a stub of a question with this enormous answer attached. Commented Jun 21, 2012 at 23:42
  • 1
    The longer until you post an answer to your own question, the more points the question gets, as people try to answer it. Most of the points are awarded within hours of posting. So waiting at-least a couple of hours will continue to be my recommendation. Unless you care nothing about points, or are a well respected user. Commented Jun 22, 2012 at 16:15
  • i found the answer by restarting the computer, should i post it as answer ?
    – Shaiju T
    Commented Mar 23, 2016 at 12:33

I've tried this once:

Optimizing Aggregate for String Concatenation

Soon after using SO I realised that it was a much better coder's blogging tool than a blog, because the editing experience is damn-near perfect for code samples. So I wondered about using it instead of a blog, and when I thought of the above "cool" demo of the power of expression lambdas, I "blogged" it as a puzzle question.

Although it ended up with positive upvotes, there was a point where it went into negative territory. I had people accusing me of gaming the site. Someone told me it shouldn't be on SO, it should be a blog post (which was the whole point of the exercise!) So I put it on a blog post, and then someone else accused me of abusing SO to drive traffic to my blog. At which point I decided... people are too weird for it to be worth the effort. Sad but true.

Then the comment from highly-repped user Lasse V. Karlsen made me realise what was happening:

Now, next time, perhaps you should ask a real question instead of just look how clever I am type of chest-beating?

At face value, it's a strange response. SO is suppose to be a repository of questions and answers, and how they get on the site won't matter to people who visit in the future. And of course I had already asked "real" questions before this. Why get annoyed? Why get personal and insulting? Why apparently take a playful puzzle question as some kind of affront to decency or a show of unacceptable arrogance? Surely whenever someone posts an answer to a question, they could be accused of saying "just look how clever I am"!

My theory is that for a lot of SO users, the reason they come to the site is because they enjoy the feeling of helping the helpless, and feeling smarter than someone else. This is not a bad thing, I hasten to add, as the end result is that people get assistance for free - it's the essence of SO and it works very well. I appreciate it a lot myself, because it feels good to help someone, and I know by trying to explain the basics I'm sharpening up my understanding of them.

The aim of SO is to produce an online resource consisting of questions matched with good answers chosen by the community, but it achieves this by having another matching function: to provide smart people with some newbies to provide help to.

Self-answered questions (or even puzzle questions answered by someone else, such as mine) do not provide the second function, and so they make people angry, sometimes without them even knowing why.

UPDATE: I just noticed that the question I referred was "closed as not a real question"!

The description for that close-reason is:

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form.

That description doesn't apply to the question - it's unusually precise, complete and specific, in a way that most "real" questions cannot be, because in those cases the asker doesn't know the answer, so they don't know what information to provide. When you ask a question that you know the answer to, you have the luxury of making it an ideal question.

Nor does it seem realistic to suggest that the question cannot reasonably be answered; the accepted answer was posted roughly 18 minutes after I asked it.

I guess the person who closed it - about five years later! - didn't know why they wanted to - they just felt strongly (yet irrationally) that it should be closed. It's a neat confirmation of the suspicions I describe in this comment!

  • 2
    The problem is that your question isn't a real question, it's a puzzle. You don't want to know anything, it's not really about string optimization so Google is going to founder on this one. What you really should have done is ask if you can override or hide Extension methods and then answered that question. Not try to use SO as a puzzle repository.
    – toast
    Commented Jul 6, 2009 at 19:11
  • I disagree. It's a valid answer to the question; people's real question are not carefully chosen to serve as optimal indexes for technical facts in answers (how could they be?) and so it's just the kind of thing someone would ask and hence get an answer. The question I posed is a practical application of a language feature, just like almost all other questions on SO.
    – Earwicker
    Commented Jul 6, 2009 at 20:54
  • 2
    As for the fact that I didn't want to know anything, that's exactly the point I make above: by the stated aim of the site (to accumulate a database of questions and answers), it shouldn't matter one iota whether the questioner knows the answer or not. But it matters to the psychology of users who are attracted to the idea of being helpful to those who know less than they do - which is a key to the success of the site, and so cannot be overlooked.
    – Earwicker
    Commented Jul 6, 2009 at 20:56
  • 1
    Puzzles aren't really helpful in this context. People who need the information cannot find it easily. I agree that what you are trying to show people is good, I just find fault in the way you presented it.
    – toast
    Commented Jul 6, 2009 at 21:01
  • But a question that someone doesn't know the answer to is a puzzle to the person asking it. It's not objectively meaningful to say whether or not something is a puzzle. Before you know the answer, it's a puzzle. When you know the answer, it's not a puzzle any more. Does that help? By the way - you're still missing my whole point, I think. I'm not saying "Everyone should become rational and realise that puzzleness is relative". I'm saying "Most people aren't rational and we just need to accept it, because it has benefits in terms of them being more helpful to others".
    – Earwicker
    Commented Jul 6, 2009 at 22:21
  • 7
    I think the 12 hour window is a bit much. When I post a question here, I'm still actively looking for an answer elsewhere. If I find an answer, I'll post it regardless of time frame. I'll also post a Q/A combo if I find an answer to a problem that is unintuitive or hard to find, but easy to correct.
    – toast
    Commented Jul 7, 2009 at 14:00
  • 1
    @Brad Jeff said many times that it's encouraged to answer your own questions. In reality though, answering your own questions is likely to go -1.
    – mafu
    Commented Apr 26, 2010 at 8:28
  • 1
    @mafutrct that's why I recommend waiting 12+ hours. Commented Apr 26, 2010 at 14:20
  • 3
    @BradGilbert: If you know of an answer before writing your question, you should post it immediately after writing the question.
    – endolith
    Commented May 8, 2012 at 14:16
  • 2
    @BradGilbert, your advice goes directly against behavior that Stackoverflow wants to encourage with its functionality.
    – Aaron Hall
    Commented Jan 2, 2014 at 3:01
  • 1
    @AaronHall It is allowed to answer your own question; you could even answer it twice if you want. I think that Jeff Atwood even said it in one of the early StackOverflow podcasts that this was allowed. You should definitely make sure that the question is good enough to stand on it's own. Which is part of the reason I encourage waiting a while before posting an answer. Plus the functionality encourages posting good answers to good questions; no matter who asks the question, or answers it. Commented Jan 2, 2014 at 4:46

While I personally feel that this is OK (in moderation), the community may not agree. An example I recently saw...

An employee of The MathWorks who is active on SO decided to post a couple of questions (here and here) that he knew were most commonly asked about their product (MATLAB). He felt that putting these questions (and their answers) in a highly visible place (i.e. SO) would help MATLAB programmers be able to easily find them. This seemed to me to be a perfectly good use of SO, and was in line with the FAQs and posts dealing with answering your own question. However, a few users responded with downvotes and a negative comment or two.

I guess answering your own question in this way is something of a roll of the dice. Sometimes the community likes it, sometimes they don't.

  • 3
    really good example
    – Bogdan_Ch
    Commented Jul 6, 2009 at 16:37
  • 1
    I will say they almost always won't like it. Commented Jul 7, 2009 at 5:39
  • He should have made them community wiki?
    – MarkJ
    Commented Sep 16, 2009 at 22:56
  • 1
    As Madison (Federalist 10) points out, people are factious in nature. There are small portions of society who are more outspoken than represented. I propose we make SO a democratic republic. Solve many of our problems :D. Commented Apr 5, 2010 at 15:09

If it was a genuine case of posting a question because you had a real problem you needed help with and then posting an answer a day or so later when you solved it - with or without the help of any answers - then I can't see a problem with it. In fact I've done it with a couple of the questions I posted on SO.

In fact I can't see a problem with posting the question after the fact, but I wouldn't post the answer straight away - you never know someone else might come up with a more elegant solution.

As others have mentioned, but the OP didn't, I wouldn't include any links to my blog in the question or answer, unless there was extra background information than could be useful.

  • 3
    Unless I'm wrong, the OP never suggested to include a link to his blog. Quite the contrary, he suggested to use SO and not his blog.
    – bortzmeyer
    Commented Jul 6, 2009 at 11:40
  • I was responding, in part, to the other answers which mentioned this.
    – ChrisF Mod
    Commented Jul 6, 2009 at 11:52
  • Questions with an answer by the person asking the question, don't seem to get that many points. I would definitely wait 12+ hours before posting your answer, otherwise most people will just ignore it and move on. Commented Jul 7, 2009 at 5:38
  • "you never know someone else might come up with a more elegant solution." Yeah, that's why you post your answer immediately. If they have a more elegant solution, then they'll post it as a separate answer and get more upvotes. If they don't, then you're not wasting their time by making them research something you've already solved.
    – endolith
    Commented May 8, 2012 at 14:17
  • @endolith - no you wait to post your answer. Some (a lot of?) people won't post an answer if they see you've self answered.
    – ChrisF Mod
    Commented May 8, 2012 at 14:19

Note: This answer is also in response to https://blog.stackoverflow.com/2012/05/encyclopedia-stack-exchange and the short exchange I had with @spolsky on Twitter about it (which is too limited as a channel to discuss this topic).

I disagree with answering your own questions or using StackOverflow as your personal blog.

The FAQ states: "You should only ask practical, answerable questions based on actual problems that you face." But the moment you ask a question you know the answer to already, you are no longer facing a problem. You already got the solution. There is no point in asking the question anymore, because you do not need help.

The only reason to add my own answer (for me) would be if I didn't get any useful answers and then managed to solve the problem on my own in the meantime. Sure, the resulting page would be the same as providing both in one go, but at least I was facing a problem then when I asked the question.

Now, I do understand that StackOverflow is a Q&A site. And by that definition, it should not matter whether you know the answer already. If you can provide both, it's still a Q&A site and maybe your question is helpful to someone with a similar problem in the future. So, all is well, right? Well. No. Because you are breaking the process.

When you provide Q and A in one go you effectively tell people: "I don't need your help. Go on. No problem here." That's broken. The community-driven problem solving process is a key element of this site. You are not supposed to take our role in this game. You ask your question to us and we will help you. We enjoy helping you. Why are you taking that away from us? We are the community. If you need to share some solution so badly, go find someone with that problem - or post it on your blog.

Furthermore by answering, you stole my chance to get the green tick. People love getting the green tick, right? Upvotes are nice, but only one person can have the green tick. It indicates a winner. Sure, the OP could decide that my answer is better, but how often do Accepted Answers get changed? Rarely. Once the OP has a working solution, the Accepted Answer stays. I have very little incentive to add my answer there.

Also, chances are "the problem" was already solved on StackOverflow anyway and I'd rather like to see good solutions added to existing Questions to have collections of quality answers instead of people spreading their quality answers into many individual posts. The latter cause duplication and make it much harder to find the good parts among them. If we want to encourage Canonicals, we need to encourage people to add them to existing questions and not each try to do their own.

Moreover, if we allow people to use StackOverflow as their personal blog, we implicitly also allow them to not care about duplicate or inappropriate content. I can write whatever I want on my personal blog. If I feel about writing a tutorial about How to format a timestamp into a specific date format I can do so. If I want to write a mini-series about what each letter in SOLID means, I can do so. If I want to write about how to use my project X on GitHub, I can do so.

But the first one would be a dupe and the second one would belong on programmers.SE and the third one is likely too localized. IMO, we already have more than enough to do fighting the dupes that come in on an daily basis for real questions (even with combined coordinated efforts). By encouraging people to abuse StackOverflow as their blog, we only make it harder for those trying keep this place tidy.

Finally, the idea that StackOverflow can substitute for my personal blog is flawed anyway. A personal blog is an individual effort. I have full control over the content. Not only can I decide the licensing terms but I can also delete content and comments at a whim. And people cannot edit my posts. This is fundamentally different on StackOverflow. I'll always have a community moderated blog on StackOverflow at best.

  • 8
    That sounds awfuly like bruised rep-hunter or ego-booster rant. It IS Q&A site, it helps not only requester, but future visitors who have same problem (and I know I benefited from many SE answers for questions I didn't ask). It is not a place to hunt for "green ticks" or permanent source of good feeling of being superior helper. I personally, value a good answer much much higher that someone's +15 points. Commented Jul 24, 2012 at 10:40
  • @Oleg This has nothing to do with rephunting. It has to do with motivation. The green tick is a strong incentive for answering on this site. It's like a mini-award and a strong part of the gamification process that drives SO. The suggested insta-answers lower chances to gain that tick for anyone (the "winner" is determined before the game already. So why play?). Hence lowering chances that someone provides another good or even superior answer for you and future visitors to enjoy.
    – Gordon
    Commented Jul 24, 2012 at 11:05
  • @Gordon: I think Oleg is right as is Earwicker with his great answer that perfectly explains to me why you are acting and feeling like this. Although I can understand what you are trying to say I still think you over-value the point system: I agree with Oleg that it is much more important that you can find a good answer to a question on SO than the fairness of the point system. Btw: Even accepted answers can be easily overtaken by more upvotes. So, that is your motivation to provide even better answers in self answered and accepted questions. It's still there.
    – Jeehut
    Commented Sep 21, 2015 at 17:07
  • @Dschee can, but rarely do. And no, I am certainly not overvalueing the rep system. Amassing more points lost it's importance long before I reached my 180k+ reputation. Out of my 3k given answers only one is a self answered one. With reasonable upvotes. It is a helpful question and I agree that this should be the ultimate result. Still, it feels like cheating to me. While I am much more relaxed about self answering than I was more than 3 years ago, I still think self answered questions take away a huge part of the gamification aspect of the site and thus a motivation to answer on those posts.
    – Gordon
    Commented Sep 21, 2015 at 17:52
  • @Gordon: Yeah you're right, most times the answer with the highest upvote is the accepted answer. But I think that is also true because usually there are several answers and often they even have already been voted way before an answer is getting accepted – and therefore the accepted answer often is the one with the highest votes and rarely another answer that came in later on. This is why I think one shouldn't feel bad about self-answering – even though it might happen anyway. But in that case one should just get used to it to not feel bad about it anymore. For the greater good! :)
    – Jeehut
    Commented Sep 22, 2015 at 7:34
  • Btw: I think the comparison shouldn't be done between non self-answering questions and self-answering questions. Instead it should be done between no question-answer pair existing and a question-answer pair existing. Because often this is the point of self-answered questions: They wouldn't have been posted at all otherwise. Therefore in my opinion the gamification aspect doesn't matter at all, it is just about providing the answer or not. The alternative would be that there is no need for motivation at all because the question simply would be missing – that would be a pity, wouldn't it?
    – Jeehut
    Commented Sep 22, 2015 at 7:39

There is a (de facto) accepted way to do this:

  1. Post your question

  2. Wait for the normal attention time span (question rolled off the main page - depends on traffic/site/time of day). Can be less than 5 minutes on SO, more so on the other sites.

  3. Optional: wait some more

  4. Post your own answer by editing the question and also incorporate some information from any answers (if appropriate)

And nobody will know if:

  1. you already knew the answer or

  2. you found it in the meantime helped by the incoming answers or

  3. you found it in the meantime despite completely useless answers

You will not be accused of reputation farming as questions usually receives much fewer votes than answers.


I think it would be ok for a few occasions. But piggybacking on the system would be frowned upon I believe.

Of course the users of whatever system would love to hear how you solved problem X but when a user gets to be known as the self answerer, we would see a lot of negative reactions towards that due to various factors.

Reputation "exploit", unfair badge earning (even if it is a CW) etc etc.

  • 4
    Is it really reputation exploitation if you've solved said problem? I think any reasonable person would be more than willing to acquiesce to another's answer if it were truly better.
    – Eric
    Commented Jul 6, 2009 at 12:05
  • So, do you suggest that it will be more fair, that, if I'm answering my own question, it will be more polite to mark it as a community wiki ? Never tried to do this, but does "community wiki" post could be marked as accepted answer? I would suggest that if question and answer belongs to the same person, he/she will not earn points, assigned to answer but will only earn reputation points for the question.
    – Bogdan_Ch
    Commented Jul 6, 2009 at 12:52
  • You can accept an answer in a CW and you won't gain any reputation if the question is a CW question. Commented Jul 6, 2009 at 13:20
  • 4
    What makes it unfair exactly? If the question and answer are worthy, they will be voted up accordingly. If not, then they won't be. We should be judging the questions and answers on their own merits, not based on who posted them. I don't think that the question or answer should be made CW because someone doesn't like the fact that the user solved his own problem and posted it here for all to see.
    – toast
    Commented Jul 6, 2009 at 15:53

Although it is possible to answer your own question and set yourself as the accepted answer, it is generally not a very well-accepted practice.

I believe that the furthest extent that StackOverflow should serve as your personal blog advertising engine is through your personal profile page. I know that I'm not the only one that tends to downvote or flag (as spam) questions and answers that tend to be little more than adverts for a blog or personal website.

  • 7
    Unless I'm wrong, the OP never suggested to include a link to his blog. Quite the contrary, he suggested to use SO and not his blog.
    – bortzmeyer
    Commented Jul 6, 2009 at 11:42

I never bothered to maintain a blog but I suppose I use SO/SF in that sort of capacity. It's not exactly a blog but occasionally someone asks a question that falls right into a pet subject and I can discuss it at length.


I had a bit of a grumble about this earlier. I'm OK with it now, as long as you make it clear what you're doing, and seriously think about making it a community wiki.

Not the answer you're looking for? Browse other questions tagged .