Look it up
Some bugs have been reported already. Before your question, make sure to search for it on Meta search or on your browser (with a site:meta.stackexchange.com addendum); I usually do both. If you find that the bug's already been reported but the question's been dormant for a while, check out How do I get attention for old, unfixed bug reports and feature requests without official responses here on Meta? for next steps.
Describe it
Your description of the bug should be succinct but clear. Make sure to communicate both what you expected to happen and what actually happened so we can clearly see the difference. If there's an error message, make sure to copy it in so we can see it. If context is important to the bug, this is a good place to describe it: what were you trying to do? How did the bug interrupt that?
Your description should always include text; that guarantees other users will find your bug report when searching and reduces duplicates. However, feel free to supplement with screenshots. If you're using screenshots, make sure not to overrely on them. Images aren't visible to those with screen readers or on slower internet connections, and they might be blurry due to compression or rendering. Additionally, an unexplained image leaves the reader guessing as to which parts are important, so they might draw the wrong conclusions or give up entirely. When in doubt, remember that explicit is better than implicit, so err on the side of text.
Show reproduction steps
In order to fix a bug, we need to reproduce it. A good bug report will make that as easy as possible. Your reproduction steps should be a clear, easy-to-follow guide—in text—describing exactly what we need to do to reproduce the problem. In some cases, you may wish to supplement those steps with screenshots or screen recordings. As above, try to get as far as you can with text; if you use screenshots, your goal should be for the post to be comprehensible without them. Video is particularly unclear because, among other things, we cannot tell when a mouse click or keypress has happened.
Make sure to test your reproduction steps; if the steps don't actual recreate the bug, they're not much good at all. If the steps sometimes work but are inconsistent, you can note that in the question.
Include debugging details
If you've tried to investigate the problem yourself a bit, feel free to add some of that information into the question. Information from browser consoles and the like can sometimes help diagnose the bug. Don't worry if you don't know how, though; this is just extra for those with experience.
Include system details
This can be a bit of a balancing act, since too excessive system details can be irrelevant and bloat your post. However, providing your browser and browser version, as well as your operating system and OS version, is rarely a bad idea. Err towards including more system details instead of fewer; if they turn out to be irrelevant, other users can just remove them from the post.
On that note, ensure that you're using Stack Exchange on a supported browser. If your bug is exclusive to unsupported browsers, it probably won't get fixed.
Tag it
Make sure the question is tagged with bug; otherwise, it might not get noticed by the right people. A good Samaritan might do this for you anyways if you forget, but it's better to do it yourself.
Keep up with it
If your bug report gets noticed, there's a good chance people will ask for more details in the comments. Make sure to edit those details into your bug report as people request them. Unattended bug reports die fast; if you want your bug to get fixed, check your notifications regularly to see if anyone's interacted with it.
How will I know something's happened?
The first sign that your post is attracting attention will be comments; the best comment you can get is someone saying that they also reproduced the bug. If your bug is reproducible, a moderator might tag it as status-review, indicating that it's been elevated to company staff. From there, it's largely in the company's hands. Continue to check on it, but understand that turnaround could take a while; there are currently over 180 bug reports in review, so your question will have to work its way through the system.
What if the question gets downvotes?
Sometimes, the downvotes will be accompanied by comments; if so, working with the commenters might bring your post back into the positive. Other times, people might be downvoting because they know the bug exists but don't think it's a priority. If so, try not to worry about it too much. You've done your share by reporting the bug; what happens after that is up to the company and community.
Examples
The following bug reports reflect the advice above.
See also