Mine was almost able to climb out at 18 months. We have one of those convertible cribs where you can take off the front, so we did that and replaced it with one of these. Now she can get in and out of bed on her own, but safely. We babyproofed the whole room and put a doorknob baffle on so she couldn't get out.
The first night she kept getting out of bed and crying because she didn't understand it was bedtime. But we just went back in every 5 minutes or so, told her it was still sleepy-time and put her back in bed. She stopped getting out of bed after maybe 20 minutes and just went to sleep. Second night and most nights since, she doesn't try to get out of bed until morning.
Maybe something like this rail