37

I would like to modify my older accepted answer, but I'm not sure whether it would remain accepted.

  • Case A: I found a small error, but it doesn't affect the main point.
  • Case B: I found a fundamental problem and it should be corrected.

To clarify what I'm asking:

  1. I wrote an answer for the question (on Stack Overflow).
  2. The questioner had accepted it. So I have a nice green tick now.
  3. But now I want to edit that answer.

After my edit what will the system do?

Will my green tick be deleted automatically by the web site (system), because I modified my answer and will a new message be sent to the questioner? Or will the green tick be retained after my edit?

10
  • 1
    Why do you want to modify it? How much do you want to modify it?
    – Makoto
    Commented May 8, 2016 at 5:37
  • 4
    @Makoto Does it really matter? Accepting an answer is the OP's choice anyway - only thing is that the answerer might not want his answer to be modified.
    – cst1992
    Commented May 8, 2016 at 6:25
  • @cst1992: You make a good point, but if the modification is due to a drastic change to the OP's question then that raises other flags.
    – Makoto
    Commented May 8, 2016 at 6:29
  • @Makoto Indeed.
    – cst1992
    Commented May 8, 2016 at 6:30
  • 3
    Whay not err... not edit it, but append to it? Draw a 'line' under the current answer, eg '------------------------------------', copy what's above the line to below, edit the copy below with an explanation. Commented May 8, 2016 at 15:06
  • 13
    Was discussed here recently meta.stackoverflow.com/questions/322563/… The consensus was Its your right to improve your answer. I edited my accepted upvoted and bounty paid answer, and the only consequence was further upvotes. Commented May 9, 2016 at 1:04
  • 5
    @MartinJames, ...my impression is that the longstanding consensus on meta has been that it's preferred to have an answer be as good at being an answer as possible -- ie. that compromising quality/readability/flow to make edit history obvious to the reader is suboptimal, as anyone who cares about edit history can easily view it. Commented May 9, 2016 at 19:26
  • 5
    @MartinJames, ...the "draw a line and amend things" approach often does compromise quality. For instance, in the bash tag, we very often have answers suggested that inadvertently promote poor practices / buggy code. Adding a note at the end that says "but don't do that thing above" leaves the thing above up there at the top where it's easy to see and copy-and-paste, and often ends up getting used by people who are just looking for some code to use and not trying to read the detailed explanation. Commented May 9, 2016 at 19:30
  • 1
    Despite this being an incredibly simple thing, kudos for asking. As long as you don't plan on changing your answer to pictures of Batman after it's been accepted, you're good.
    – Insane
    Commented May 9, 2016 at 23:03
  • @MartinJames When you want to make it clear that you've appended new material to an answer you don't need to type a row of dashes or underscores, just use the HTML <hr> horizontal rule tag. In most cases there's no real need to be explicit like that: just improve your answer and let the curious readers check the edit history. OTOH, I do occasionally add stuff with an explicit edit, eg with chameleon questions, or when modifying someone else's faulty answer when the original author is no longer active / doesn't respond to comments.
    – PM 2Ring
    Commented May 10, 2016 at 13:22

4 Answers 4

29

I think you're a little too worried about this.

Will my green tick be deleted automatically by the web site (system), because I modified my answer and will a new message be sent to the questioner?

The answer to this is no and (probably) no:

  1. The only one who can un-accept an answer is the OP.*
  2. The edit will notify anyone who followed the post. Maybe OP followed the post (you have no way of knowing), but most people don't follow many posts.

Of course, an edit will bump the post, so everyone browsing the active tab will see that you edited it. And anyone on the page can see when the last edit was. If they click on the revision history, they will be able to see what you changed.

Realistically, nobody cares enough to do that. In fact, it's likely that the OP doesn't care, either. As long as your edit improves the answer, you shouldn't feel guilty about it.

If you really want to preserve the content that your answer originally had, you can simply add the changes at the end of the post.


* Note that getting accepted does NOT prevent deletion:

moderators are not restricted from deleting accepted answers... And neither are 20K users.

14
  • 14
    Moderators can't unaccept answers, and never have been able. Accepting answers is treated like a vote on the database, and the only ones that can modify those are SE employees (and not everyone either).
    – Braiam
    Commented May 8, 2016 at 21:53
  • 2
    It wasn't the moderator... as the moderator points out.
    – Braiam
    Commented May 8, 2016 at 22:16
  • @Braiam I've added more sources that would indicate that Mods do have this privilege.
    – Laurel
    Commented May 8, 2016 at 22:22
  • 4
    "Dori Smith used to be a community manager." A CM is not a moderator, is a employee, and even in that case Dori deleted the answer, she did not unaccepted it. On the other "source", is just another clueless user. Moderators can't and never will be able to unaccept answers.
    – Braiam
    Commented May 8, 2016 at 22:52
  • @Braiam It might be true that not all mods have the power, but CM and such are just a superset of moderators, just as mods are a superset of users.
    – Laurel
    Commented May 8, 2016 at 22:59
  • 5
    No... Moderators aren't even paid, while CM's are explicitly paid (some CM's were moderators at some time, just not now). The moderators are elected by the community, the CM's are not. This is what all moderators can do while CM's can do that and much more, they can even see who voted for each post, and some other shenanigans, which as you can notice, moderators can not.
    – Braiam
    Commented May 8, 2016 at 23:04
  • @Braiam That doesn't include enough details about edge cases. If mods have the ability to turn answers into comments, what happens when they try that on an accepted answer?
    – Laurel
    Commented May 8, 2016 at 23:10
  • 3
    Converting answer into comments is just a glorified tool that deletes the answer and post a comment on behalf of the user that wrote the answer.
    – Braiam
    Commented May 8, 2016 at 23:11
  • 1
    Mod's cant unaccept anwsers..
    – amanuel2
    Commented May 9, 2016 at 1:35
  • 2
    Moderators can't unaccept answers. We can delete an answer that has been marked accepted, but as soon as a moderator undeletes the post the answer is marked as accepted again.
    – Martijn Pieters Mod
    Commented May 9, 2016 at 6:20
  • 1
    'Conversion' to a comment is simply two actions: delete the post, and repost it as a comment (on behalf of the user who posted the answer). It is still a delete, we can undelete the post again. For unaccepted answers that means the accept vote is still there and the answer is still marked as accepted. The comment is not automatically deleted again.
    – Martijn Pieters Mod
    Commented May 9, 2016 at 6:25
  • 1
    And don't confuse CMs with moderators. Specific employees can perhaps mark an answer as accepted by adding an 'accept' vote to the database (I don't know if there is a UI for this action even), CMs are employees and are usually given this level of access (but it is not a given they get this access, most employees of Stack Overflow don't have this level of access). Doing this would be extremely rare; I am not even aware of any cases where this happened.
    – Martijn Pieters Mod
    Commented May 9, 2016 at 6:29
  • @Braiam Never say never
    – TylerH
    Commented May 9, 2016 at 22:35
  • I think it's important to focus on the quality of content, and not whether you have the accepted tick or the reputation for it.
    – scrowler
    Commented May 11, 2016 at 3:49
9

An answer of mine was accepted. What happens if I modify it?

Nothing at all. Well, something actually happens, just nothing to do with the accept vote. Whenever you edit your post a bunch of things happens, even if it's not the accepted answer. The OP is the only one with the power to accept any answer they like, with the biggest exception being Stack Exchange developers and CM's, but they don't use this unless there's a very good reason:

It is maintained by the community, but a Stack Exchange developer changes the Accepted Answer to ensure that the latest changes remain on top (given default user settings).

7

Your ultimate goal should be to make the Q&A useful for future readers, as well as the original poster of the question.

They don't get notified about changes you make, so you can leave a comment on the question to notify them about something important you changed. An @username comment on your answer won't work unless the OP has already replied to your answer. (If @us... doesn't show the OP's username as a possible completion, you can't ping them with a comment there.)


If there was an error in your solution, you definitely should make an edit to address it. If the problem is serious enough that nobody should ever use your solution, even though it might appear to work, you can even delete your answer to prevent misleading people.

If your edit drastically changes your answer, taking a different approach altogether, it should maybe be a different post (and delete the old post), esp. if there was a discussion in comments on the wrong answer that's no longer relevant to the new answer.

In general though, it's ok to change your answer a lot, even if it's already accepted. The OP might un-accept it, but that's ok. As long as you think your edit makes your answer good enough to be the accepted answer to the question, go for it.

It's (very?) rare for an answer to be accepted before the answerer notices a fatal flaw. Even totally rewriting the answer, with maybe a note at the end that the old version had whatever flaw, is usually fine. The note at the end avoids confusion for anyone reading the comments later, if the comments are talking about the old version.

4

If the answer was good and you made it better, so much the better! Clearly nothing to worry about.

If the answer had a serious error (and you're feeling guilty that the original poster accepted it anyway), you can put a comment on your edited answer, pinging the OP. (I've done that.)

The only cause for concern might be if that you took your already-good answer and "augmented" it with some heretical advice, which if you'd included it originally would have caused everyone to downvote it, but now that some time has passed and the "nice" answer has been upvoted and accepted, you're hoping to get away with it. But I've never heard anyone worrying about this. (There was one time I modified one of my answers in what I was afraid might have been construed as this sort of a way, but nobody complained.)

You must log in to answer this question.

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