Looking for a space adequate to this opening is your first step.
Garage attic opening size.
Buildings with combustible ceiling or roof construction shall have an attic access opening to attic areas that exceed 30 square feet 2 8 m2 and have a vertical height of 30 inches 762 mm or greater.
Standard openings are 22 5 x 54 but some homes have wider openings.
Full size attic ladders usually need an opening in the ceiling that is at least 22 1 2 x 54 inches.
Measure the rough opening in your ceiling both the width and length.
An attic access opening runs between the ceiling joists whenever possible.
The 2007 california building code requires a minimum attic access opening of 20 inches by 30.
Unobstructed headroom of at least 30 inches must be available above the attic opening.
Minimum opening size the 2012 international residential code requires an attic access opening for attics with an area greater than 30 square feet and a vertical height in excess of 30 inches.
Also make sure there is a suitable landing space in the attic so you can safely mount and dismount the ladder while carrying items.
If mechanical equipment or appliances are housed in the attic there must be an unobstructed passageway large enough for the removal of the appliance.
Conversely some homes have smaller openings or hatches.