As soon as the kid is old enough to talk, it's time to start talking to them about firearms.
As soon as the kid is old enough to walk, it's time to start teaching them the basic Eddie Eagle safety rules ("If you see a gun, STOP! Don't touch. Leave the area. Tell an adult.")
There is no such thing as a child old enough to walk and talk, but too young to defeat "childproof" storage. I say this as a woman who raised five sons (see
www.corneredcat.com/Childproof_Locks/ ).
Get a copy of Massad Ayoob's old but excellent book,
Gunproof Your Children and follow the steps in it.
pax