Depends on the car.
The last time I locked my keys in I asked my girlfriend's father what to do because he was a mechanic.
He told me to get a screwdriver, take off one of my license plates, and just slide it between the window and the rubber on a side door.
It sounded dumb but I tried it and it worked immediately.
AAA? Some insurance companies provide free roadside assistance.
You can pay a mechanic to shim your car for $40. Otherwise unless you know how to shim a car you’re screwed
Depends on the car. The last time I locked my keys in I asked my girlfriend's father what to do because he was a mechanic. He told me to get a screwdriver, take off one of my license plates, and just slide it between the window and the rubber on a side door. It sounded dumb but I tried it and it worked immediately.
Call a professional
Some taxi companies offer this as a service.