Question special

We all know that letters of recommendation are a great way to get to know an applicant. They describe their work ethic, camaraderie, intellectual abilities, but also their struggles. They serve to provide context in a way that the rest of the application is unable to.
What makes a good letter of recommendation and how can an applicant maximize their changes of getting a letter that makes the most difference?