This is a form of, "Kedging," bit there is a manual way also.
If having a dingy, run out 15-20 yards depending on depth, hardness of ground
anchor type & length of rode.
Make sure of course, that the anchor is with you in the dingy & having a free payout of line
from your boat as you go. Drop the anchor & take the dingy back to boat.
Tie the anchor to the end of your halyard & start cranking it up with winch slowly.
The boat will at first lean over then if free, will round the bow to the direction of where the anchor is set.
Disconnect anchor line from halyard, keeping tension on the anchor line to hold you in place.
pull up close to the anchor without pulling it free, crank up the motor & that's it,
"Your are now Ungrounded."
This has worked for me on my boat once & two other boats I happened to be on.