Choose decay-resistant wood in a finish or color matching your deck's wood. The railings may be whatever desired thickness you want, as long as they are at least 1 1/16 inches thick, for best endurance in the outdoor elements.
Place the two posts at the top and the bottom of your staircase, respectively, using two clamps to secure them to the stairs' stringer. The stringer is the portion that creates the rise in the stairs and supports the steps (treads).
Check with a bar level to ensure that the posts are level and perfectly perpendicular to the ground.
Secure the posts to your stairs' stringer wood using two hex bolts through each post placed vertically about 2 inches apart. The posts should extend about 36 inches above the treads, or at a height comfortable to use as a handrail.
Cut the tops of the posts using a handsaw at a 45-degree angle downward, or at a similar angle to your stairs' slope downward. File by hand to achieve a perfect cut.
Measure the length between the posts and including the posts, and use that measurement to cut your three railings: the railing cap out of the 2-by-4, and two additional railing components out of at least 1 1/16-by-3-inch-thick pieces.
Nail the 2-by-4 railing cap to the top of the posts. Nail an additional railing to the posts so its skinnier side is flush with the bottom of the railing cap you just attached.
Measure 6 inches down from the railing cap on each post and mark with a pencil. Nail the third railing piece to the posts at these marks. This piece helps make the railing more sturdy.
Sand the edges and top of the railing so no splinters will hurt people's hands.