In most cases, the title is the most important edit you can perform. This is what shows on lists of questions, whether that's the home page, the tag page, related questions down the side, possible dupes, or many other places. Yet most users (even experienced ones) choose horrible titles.
A good title:
- is an actual question, often starting "how do I" or "why does"
- does not contain any markup
- does not contain words like question, problem issue, broken, not working, or the like
- does not contain tags
- summarizes the issue the user is facing (read the whole body to gain this understanding, then share it with others by editing the title.)
So for example on Travel, a question might have the title "Family trip to Greece" but when you read the body, it's clear they are asking about ID requirements at hotels, or transit visas, or permission letter from one parent to let the other parent take a child out of the country. So you edit the title to make it clear what the question is about.
On code-oriented sites, if the user has mentioned an error number, a short error message, or a keyword, it's probably a good idea to have them in the title. "Why am I getting C2202 when I know I declared the function?" is better than "Complier is lying that something is mssing that is NOT MISSING" even if the latter better captures the emotional state of the user. [I made up the error number, please don't judge me, also "typos" in bad title are deliberate.]
It's my observation that people who are bad at writing titles in the Stack Exchange "style" are also generally bad at tags, so check those while you're doing the edit. Writing a great title is hard. Improving a bad title, even if you don't get all the way to great, is worth it.
If you have read the question carefully and can't figure out a good title, that is a strong clue that you can't figure out what the question is or how to answer it. If you can flag or vote to close as "unclear what you're asking" this would be a great time to do so. Consider also leaving a comment asking for the details or clarity that are missing.