Railroad ties make excellent garden wall material in gardens that will not contain edible plants. You can stack railroad ties one on top of the other, with each layer secured to the previous layer using long zinc or stainless steel spikes. Stagger the railroad ties so that the joints of each layer do not line up with the layer beneath, for added stability.
If you have an existing retaining wall, constructed of cement blocks or wood, you can construct a new wall just outside the old one, using railroad ties. This alleviates the extra effort of having to shore up the old wall and remove and dispose of the old materials. Simply construct the retaining wall just outside the old stone or wooden wall, securing the first layer to the ground using stakes, and securing each successive layer to the one beneath it with spikes.
In a landscape that contains a lightly sloping topography, a graduated, or step design railroad tie wall is popular. You can create these by constructing a wall starting at the lowest part of the hill. This part should be equal in height to the height of the highest point of the hill. You then construct your wall, omitting a layer of ties as you get closer to the peak of the hill. Once the wall and the hill are level, add a single additional layer, laying across the top of the wall and the top of the hill to complete the look.
If you are constructing a wall of significant height, more than 4 feet, you will want to further secure your wall to prevent it tipping over. Sink metal reinforcing bars into concrete along the perimeter of the area you intend to wall in. You can then redrill the railroad ties to slide them over the rebar for a secure, long-lasting retaining wall.