How do you beat the Widow in Hollow Knight: Silksong?

Quick answer: Dodge her bouncing bells and blade dashes, stay in the air during her charge, and punish her recovery windows. Use Silkspear when she is stunned.
Show walkthrough
Bouncing bells
She throws bells that bounce in all directions and cannot be blocked. Dodge them and counterattack once they pass. If you face where they come from, you can also parry them.
Running charge
The Widow runs at you while bells and metal scraps burst from the ground. Jump and use the Drifter’s Cloak to stay in the air until it ends. Hit her once she stops.
Blades and falling bells
She jumps and strikes with blades, sometimes followed by a dashing combo, so move out of her path or float over her. When she threads silk above, bells rain down; move to the other side of the arena. Her recovery after these moves is your best chance to attack.
Phase two
In the second phase her bell and blade attacks get faster and stronger. Do not get greedy, because one mistake costs a lot of health. When she is stunned she stays open for a while, so use strong skills like Silkspear then.
Reward
Beating her gives you the Needolin and breaks the curse on Bellhart. Her room becomes a bench. See the Bellhart walkthrough for what opens up after.
