The PECOTA article on Wikipedia goes into some detail about the various factors considered in the projections but they don't reveal the secret sauce recipe.

This BP article gets more into the math.

This article from Fangraphs is a summary level comparison of some of the many projection systems out there. At some level, they're all weighted averages of past seasons with some adjustments for regression, park factors, aging, etc. All of them are useful but I think it's kind of risky to aggregate their importance when evaluating players. Because their methodologies are somewhat similar, they tend toward groupthink. The rare cases when one system's projection is way off from the field are more interesting to me. Fangraphs lists three projections: Bill James, Steamer and Oliver. The latter is generally the most pessimistic with greater negative variance compared to the other two. This isn't true for all players though. Usually the three projections are pretty tightly clustered. But when there is an outlier, it's usually Oliver guessing on the low side.