Are you talking about the original pin-up style, or the revivals of it? The original pin-ups were a feature of WWII, as pictures for soldiers to literally pin up in their barracks. Do an image search for "Betty Grable" to see what I mean. The photograph of her from behind looking back over her shoulder is THE iconic pin-up shot.
In the postwar period the returning GIs fostered a relaxed sexual code in a racier, go-go Googie atmosphere of new wealth and leisure that made female nudity more acceptable, not to mention the numerous obscenity court cases of the time that changed what was allowable to print, and the pin-ups got sexier. The exemplar here is the famous picture of Marilyn Monroe naked on a red backdrop that appeared in the first issue of Playboy in 1953. There were loads of "skin mags" before Playboy but they were sleazy and not stocked by reputable newsagents, or if they were it was strictly under the counter.
The advent of actual nude photographs being available to men pretty much killed off the more modest pin-ups. I would place the classic pin-up era between those two times, say 1942-1954. There were (and are) still pin-ups, on things like tool company calendars, but the style of the things gradually devolved from "pretty girl next door in a cute outfit" to "oiled-up porn star pretending to fellate a wrench".
You could include in the intermediary time such iconic images as the perky poster of Farrah Fawcett that did, in fact, once hang over almost every teenage boy's bed in the 70s. And there are antecedents too, like the "Gibson Girls" going back to the 1890s in their smokin' hott floor-length dresses with big bustles. Whew! But the real classic period is mid-forties to mid-fifties, with the look progressing from Betty Grable's swimsuit to Bettie Page's hairstyle, which has become an icon all its own. Bettie Page was a classic pinup model in addition to her kinkier nudes and spanking pics.
If you're talking about revivals, the first one was in the late-70s-early 80s, roughly coexistent with the spread of punk rock to the suburbs, and the rise of neo-rockabilly. For a while there all the girls wanted to look like Bettie Page (the Grable look has never really been revived, though it ought to be), and all the boys wanted to look like Robert Gordon. Since then, there have been so many retro styles colliding with each other all at the same time you really can't pin a year on it. I see Bettie Pages walking around all the time even today. Walk into a tattoo shop! Although they're more likely to be wearing cowboy boots now.