I tie one end to a doorknob.
Other end to a racket throat.
I always wonder if there is a correct knot for this application.
Then I just tie some shoelace sorta knot and not give a crap and forget about it.
You want a knot that:
A. Has no chance of slipping when you pull up to 100 lbs of tension.
B. Has low risk of breakage at the knot.
C. Has low risk of breakage where it is pulled against the anchor.
D. Doesn’t waste too much string.
I use a loop of 3/16” braided nylon rope.
When I am home, I use a loop of the rope and slip it over the end of my bar countertop as an anchor. Then tie the string to the rope with a triple hitch.
If I was using a doorknob, I’d use two loops of rope. Use the second loop to tightly secure the first loop to the door knob. Then tie the string to the first loop using a triple hitch.
Using the rope ensures that the string doesn’t have to go around any solid objects. And saves wasting string.