## How do comments work? Comments exist so that users can talk about questions and answers without posting new answers that do not make an attempt to answer the question asked. Comments are often used to ask for clarification on, suggest corrections to, and provide meta-information about posts. The post author is notified of new comments to their post. Comments are intentionally short, having maximum length of 600 characters, **and a minimum length of 15 characters**, not counting stripped characters (will get to this in a moment). They allow only limited markup. URLs in comments automatically become hyperlinks. Each user may post only one comment every 15 seconds. Optionally, a comment can contain an [@reply](https://meta.stackexchange.com/questions/43019/how-do-comment-replies-work), which causes a certain user who commented or edited the post to be notified, in addition to the author. Comments on posts can be upvoted by other users with the *comment everywhere* privilege (see *Who can post comments* below), if they believe that the comment contributes something useful to the post. They can also be flagged by users with [the *flag posts* privilege](/help/privileges/flag-posts) if they violate the commenting policy (see below) or the Code of Conduct. For more information on how these mechanisms work, see https://meta.stackexchange.com/q/17364/377214 Comments are disposable: unlike posts, there's no public revision history, and they can be deleted without warning by their authors, by moderators, and in response to flags. ## What are comments for, and when shouldn't I comment? Comments [are for](https://stackoverflow.com/help/privileges/comment), and should be used to: - Request **clarification** from the author - Leave **constructive criticism** that guides the author in improving the post - Add relevant but **minor or transient information** to a post (e.g. a link to a related question). They are **not** for: - **Providing additional information** that may be needed to formulate an answer; instead, important information from the original author should be [edited](https://meta.stackexchange.com/a/21789/377214) into the question - **Suggesting corrections** that don't fundamentally change the meaning of the post (such as grammar or formatting); instead, [edit](https://meta.stackexchange.com/a/21789/377214) the post or [suggest an edit](https://meta.stackexchange.com/q/76251) - **Answering a question** or providing an alternate solution to an existing answer; instead, post an actual answer (or edit an existing one) - **Compliments or criticisms** which do not add any new information to the post (e.g. "great answer", "this is bad", etc.); instead, upvote or downvote (and provide or upvote a better answer if appropriate) - **Secondary back-and-forth discussion** or debate; use chat instead - **Discussion of behavior or site policy**; use the site's per-site meta instead ## Who can post comments? - All users may comment on their own posts and any answers to their own questions. - Users with the [*comment everywhere* privilege](https://stackoverflow.com/help/privileges/comment) (50 reputation on most sites) may comment on any post (with some exceptions; see *Why can't I comment on specific posts?* below). - On Meta Stack Exchange, only 5 reputation is required; on Stack Apps and private beta sites, there is no requirement. The reasoning behind this reputation requirement is explained at https://meta.stackexchange.com/questions/214173/why-do-i-need-50-reputation-to-comment-what-can-i-do-instead. If you can't comment on one of your *own* posts because you don't have 50 reputation, please ensure that you're signed into the same account as the one that made the post; if necessary, file an account merge request by filling out the [contact][1] form linked in the footer on any site. ## Who can edit comments? Users may edit their own comments any number of times for five minutes after they are first posted. Edited comments are marked with a little pencil icon, and a mouseover tooltip over that icon will provide a count of how many times the comment was edited, like this: <sub>![Pencil icon](https://i.sstatic.net/s0kWJ.png "this comment was edited 2 times")</sub> Moderators can edit any comment at any time. Moderator comment edits are logged and visible to other moderators. Such edits [will][2] also show the pencil icon. In all other situations, comments cannot be edited. However, in lieu of editing, they may be deleted and resubmitted. Moderators can also see the edit history of any comment, regardless of who edited it, by clicking the pencil icon on the comment - provided the comment was added after October 2012. ## How can I format and link in comments? Comments can be [formatted with a subset of Markdown][3]: **bold** (`**bold**`), *italic* (`_italic_` or `*italic*`), ***bold italic*** (`***bold italic***` or `___bold italic___`) and `code` (<code>\`code\`</code>) are allowed. It is not generally possible to insert line breaks in comments, though some [hacky workarounds](https://meta.stackexchange.com/questions/3122/formatting-sandbox/72773#comment236011_72773) exist. HTML formatting is not supported in comments - the elements will show as text instead. URLs will be automatically converted into actual links. Links are also allowed by using the Markdown syntax `[link text](https://myurl)`, and there are certain ["magic links"](https://meta.stackexchange.com/questions/92060/add-data-se-style-magic-links-to-comments/94000#94000) that will be converted to real links automatically. Spaces are not allowed in link URLs in comments (even Markdown); for example this: `[URL](https://google.com/?q=stack overflow)` will not generate a link. It needs to be encoded like this: `[URL](https://google.com/?q=stack%20overflow)`. Sites that have MathJax enabled can use it in comments. For more information see the guides [linked in this answer][4]. See also: https://meta.stackoverflow.com/editing-help#comment-formatting Also see: https://meta.stackexchange.com/a/79981/187824 ## My comment doesn't contain some of the text I typed in it / My comment appears to be long enough, but I can't post it because it's too short; why? Upon posting a comment, any extra whitespace between words will get collapsed into one space, any whitespace at the end will be stripped, and unnecessary @replies (directed at the post author, where the post author has not commented, and which are at the beginning) will be removed. If the length of your comment after this processing is less than 15 characters, you will get an error message and your comment will not be submitted. (Note: the character indicator below the comment field does not take into account stripped characters, so you may get an error that your processed comment isn't long enough even when the counter says it is.) ## Who can delete comments? A user may delete one of their own comments at any time by clicking on the "Delete" button that appears to the right of the comment's timestamp when the comment is moused over. Comments that are flagged by multiple users are deleted automatically. The number of flags needed is usually [based on the comment's score](https://meta.stackexchange.com/questions/138168/reduce-the-threshold-for-comment-deletion-with-flags?lq=1#comment388189_138168). It currently takes "`3 + (Score / 3)`" flags (rounded up) to delete a comment. Comments containing certain keywords can be deleted with a single flag. Moderators can delete any comment, or purge *all* comments from a post. They also have the ability to move all of a post's comments to chat. Automatic comments from the Low Quality Posts queue on answers that aren't deleted from the queue are automatically deleted by a weekly script if no other user replied to them. (See *What are automatic comments?* below for more info.) ## When should comments be deleted? [Comments are temporary "Post-It" notes left on a question or answer](https://meta.stackexchange.com/help/privileges/comment). You should not expect them to be around forever. Once a clarification has been made, an edit added to the post to include new information, or the issue in the comment is otherwise resolved, it can be deleted. Additionally, any comment that violates the comment guidelines listed above or the [Code of Conduct](/conduct) is subject to deletion. In reality, on most sites, many since-obsolete or guideline-violating comments don't end up being deleted due to the high volume of comments posted, but this does not mean that they can't or shouldn't be deleted in the future. If you encounter a comment that has since become obsolete or that violates the commenting guidelines above or the Code of Conduct, you can [flag](https://meta.stackexchange.com/q/17364/) it for deletion. ## Why can't I comment on specific posts even if I have enough reputation to comment? Unless you're a moderator, you can't comment on posts in the following cases, even if you have the *comment everywhere* privilege: - The post is deleted. - The post is [locked](https://meta.stackexchange.com/a/22229/377214). - You're trying to make the comment through the review interface (specifically, the Low Quality Posts review queue). - A moderator has manually disabled comments on it. ### Why do moderators disable commenting on some specific posts? When a post continues to attract comments that have to be routinely/repeatedly deleted or moved to chat (because they go against the purpose of comments listed above or violate the Code of Conduct), a moderator may disable comments on it for a certain period of time. Posts that have comments disabled can still accept other interactions - votes, flags, new answers, etc. - but can't be commented on by normal users. Note that prior uses of the old "off-topic comments" lock reason have since been remapped to uses of this feature. ## When can comments be undeleted? Only moderators can undelete comments. When looking at deleted comments on a post, moderators are not provided with a button to undelete the comment unless the comment was deleted by a current moderator. Moderators can undelete any comment from the page listing all of the specific user's comments, regardless of who deleted the comment. See *Miscellaneous information* below for more information. ## What are automatic comments? In several cases, the system will automatically add comments to posts on your behalf. You will still own the comment, and it will appear the same as if you had manually posted the comment. You may edit or delete the comment if you desire, but **deleting is discouraged** as it isn't helpful to the original poster: the automatic comments provide information on how to improve the post or why it is not appropriate. (Automatic comments can also be generated on behalf of users who don't have enough reputation to comment; these users cannot edit or delete those comments.) - When someone flags or votes to close a question as a duplicate, the system automatically posts a comment to that question which reads "This question is similar to: [link]". [The comment will be automatically upvoted](/q/218295) whenever someone else votes or flags to close as duplicate with the same question link - in that case, an additional comment won't be posted. The comment will be automatically deleted if the question is closed as a duplicate, provided it's not been edited. - When voting (not flagging) to close a question, the user can choose "A community-specific reason" and choose "other", adding a custom reason. When doing that, a comment will be added on their behalf with the exact text they wrote, usually something like "I'm voting to close this question because...". The comment will be shown as an available "community-specific" close reason for others voting to close, and the comment will be automatically upvoted if someone else votes to close and chooses that option. - When choosing the "Recommend Deletion" action in the Low Quality Posts review queue, an automatic comment will be added to the actioned answer, unless the user selects the "no comment necessary" option. If the selected automatic comment is already present on the post, a duplicate comment will not be added. - If the answer leaves the review queue without being deleted, the comment will be automatically deleted by a weekly script, unless [someone else replied to the comment](https://meta.stackoverflow.com/questions/317388/a-lot-of-while-this-link-may-answer-the-question-whats-happening/318484#comment653026_318484). - If you post an answer that is very short and consists of an internal link to anywhere on the Stack Exchange network, it will be considered a "trivial answer" and will be automatically posted as a comment instead. - If a user is prompted by the system to continue an extended conversation in chat (see below) and chooses to do so, an automatic comment will be posted with a link to the relevant chat room. - When a moderator moves a post's comments to chat, an automatic comment will be posted with a link to the chat room. ## How can I link to comments? The timestamp at the end of each comment is a permanent link to that comment. This behavior has existed [since January 2012](https://meta.stackexchange.com/a/120688/131713). Before then, it was [not officially possible][5] to directly link (permalink) to comments, though an [unsupported workaround][6] existed. Do note that comment timestamps on Area 51 do not have these links, though the above unsupported workaround still works for them; since Area 51 runs on a 2011 fork of the Stack Exchange engine, the ability to link to comments from timestamps isn't implemented there. ## Miscellaneous information - If you post a comment within five minutes of someone else making or editing a post, your comment will [end the grace period][7] for that user. - If you and another user post at least four pairs of back-and-forth comments to each other, the system will prompt you to avoid extended discussion in comments and will give you an option to continue the discussion in chat. - You can only delete [20 of your own upvoted comments](https://meta.stackexchange.com/questions/272762/comments-without-up-votes-can-be-deleted-even-past-a-user-s-daily-limit/272766#272766) (comments with at least one upvote) per day. Comments that haven't been upvoted don't count toward this limit. - Moderators can only move a post's comments to chat once. However, users "continuing" a discussion in chat won't prevent a moderator from moving comments to chat, though it creates a second chat room rather than adding new comments to the existing room. - Moderators have the ability to convert an existing answer into a comment. Line breaks will be omitted, reference footer links will be converted to inline links, image embeds will be converted to links with the description as the link text, and the exact same Markdown will otherwise be used to form the comment. The length of the comment after this processing must not exceed 600 characters. Note that this is only done in *exceptional* cases, if an answer makes no attempt to answer the question but is still valuable for some reason. - Only comments that are deleted by a current moderator can be undeleted by moderators when the moderator is looking at deleted comments on question pages. The check for whether a moderator can undelete a comment checks moderator statuses live, rather than checking if the deleting user was a moderator at the time of deletion, so a comment that was voluntarily deleted by its author can be undeleted if they later became a moderator, and a comment that was deleted by a former moderator can't be undeleted from the user interface on question pages. Any comment can be undeleted when the moderator is viewing the pages which list all comments created by a user, regardless of who deleted the comment. - Users still get notified of comments on deleted posts [up to one hour after deletion][8]; only mods can comment on deleted posts. [1]: https://meta.stackexchange.com/contact [2]: https://meta.stackexchange.com/questions/66386/can-anyone-at-all-edit-my-comments/66387#66387 [3]: https://blog.stackoverflow.com/2010/01/new-improved-comments-with-reply/ [4]: https://meta.stackexchange.com/a/288209/284336 [5]: https://meta.stackexchange.com/questions/5436/direct-link-to-a-comment/44119#44119 [6]: https://meta.stackexchange.com/questions/5436/direct-link-to-a-comment/27319#27319 [7]: https://meta.stackexchange.com/a/251876/377214 [8]: https://meta.stackexchange.com/a/231990/176060