A large share of people accept the first offer without discussion. Employers generally expect negotiation and build room for it, so the person who does not ask is leaving money that was budgeted.
Before the conversation
Research the range. Job listings with published ranges, salary surveys for your role and location, and asking people in similar positions. Vague sense is not enough; you want a number range you can state.
Know your own floor – the figure below which you would decline. Deciding that in advance prevents accepting something you will resent.
The timing
After an offer, not before. Once they have decided they want you, the dynamic changes entirely.
If asked for expectations early, giving a range based on your research is reasonable, and asking what they have budgeted is also reasonable.
What to say
Something direct and unapologetic. That you are pleased with the offer, that based on the market and what you bring you were expecting closer to a specific figure, and whether there is flexibility.
Then stop talking. The silence is uncomfortable and it is doing work.
Beyond base salary
If the salary is fixed, other things frequently are not. Additional leave, flexible arrangements, a training budget, an earlier review date, a signing amount.
What not to do
Justify it with personal expenses. The relevant argument is market value and your contribution.
Bluff about an offer you do not have. It is occasionally called and it ends badly.
The realistic expectation
Sometimes there is no room. Asking politely and accepting a firm no costs nothing and is not held against you by any reasonable employer.