The sonnet begins with a bold assertion: sex isn't worth the painful cost of lust. The speaker calls sex an "expense of spirit," to be more specific, a metaphor that implies that sex uses up one's mental and physical (and, of course, spiritual) energy.
This suggests that sex actually costs people something. Not only that, but it's little more than a "waste of shame"—an idea that frames sex not only as a pointless use of energy, but also as something that leads to guilt (perhaps because people feel ashamed of their feverish sexual desires once these desires have been satisfied).
All of this, the speaker says in line 2, is what "lust in action" amounts to ("lust in action" is yet another euphemistic way of talking about sex, since acting on lust means actually having sex). "Lust," then, is something capable of driving people to deplete their "spirit" and vitality as they go looking for a sexual release.
The first line establishes the sonnet's use of iambic pentameter, a meter consisting of five iambs (metrical feet made up of an unstressed syllable followed by a stressed syllable, da-DUM):
Th' expense | of spir- | it in | a waste | of shame
(Note that "Th' ex" is meant to be read as a single syllable here.) This is the standard meter for Shakespearean sonnets, and generally mimics the natural lilt of English speech.
The speaker also uses sibilance of /s/ and /sh/ sounds in these lines:
Th'expense of spirit in a waste of shame
Is lust in action; [...]
These soft sounds make the language feel gentle and inviting, reflecting the enticing nature of sexual desire. Sibilance also might call to mind the hissing of a snake, or a hushed whisper. The sounds of these lines thus evokes the slippery deception of lust, which the speaker believes pushes people towards torment. The poem's language itself illustrates just how difficult it is to resist sexual desire, even if such desire only leads to a "waste of shame."